Customizing GCodeDisplay

More
6 years 1 month ago #184137 by phillc54
Is there a way to change colors, fonts, backgrounds etc. with stylesheets for the GCodeDisplay?

After playing around I managed to change the ScrollBars with a qss file but I couldn't change anything else.

I did manage to change some of the margin stuff from the handler file but I don't seem to be able to get any further.

This is what I did manage to do:
Warning: Spoiler!

Please Log in to join the conversation.

More
6 years 1 month ago #184153 by cmorley
Replied by cmorley on topic Customizing GCodeDisplay
AFAIK there is no way to change colors of the actual editor with stylesheets.
There is not a lot of info on scintilla/Qscintilla.
The best reference links are in the gcode_editor.py file

Chris

Please Log in to join the conversation.

More
6 years 1 month ago #184160 by cmorley
Replied by cmorley on topic Customizing GCodeDisplay
I could add a hook to catch when the styling changes and call a function in the handler file so you can parce it and decide what to do.

Please Log in to join the conversation.

More
6 years 1 month ago #184162 by cmorley

Please Log in to join the conversation.

More
5 years 11 months ago #190137 by persei8
Replied by persei8 on topic Customizing GCodeDisplay
I see you have now added the ability to style the gcodeDisplay via .qss file but none of them seem to apply to the line numbers in the left margin. The default black is hard to see with a dark background. Can this be added or should I set a lighter background? Thanks.
Jim

Please Log in to join the conversation.

More
5 years 11 months ago #190185 by cmorley
Replied by cmorley on topic Customizing GCodeDisplay
I think I could - I'll look into it.

Please Log in to join the conversation.

More
5 years 11 months ago #190189 by cmorley
Replied by cmorley on topic Customizing GCodeDisplay
ok pushed to master, here is the full deal - note background color setting has changed from previous:
Code:
EditorBase{ qproperty-styleColorBackground: lightblue; qproperty-styleColor0: black; qproperty-styleColor1: #000000; /* black */ qproperty-styleColor2: red; qproperty-styleColor3: black; qproperty-styleColor4: yellow; qproperty-styleColorMarginText: White; qproperty-styleColorMarginBackground: blue; qproperty-styleFont0: "Times,12,-1,0,90,0,0,0,0,0"; qproperty-styleFont1: "Times,18,-1,0,90,1,0,0,0,0"; qproperty-styleFont2: "Times,12,-1,0,90,0,0,0,0,0"; qproperty-styleFont3: "Times,12,-1,0,90,0,0,0,0,0"; qproperty-styleFont4: "Times,12,-1,0,90,0,0,0,0,0"; qproperty-styleFontMargin: "Times,14,-1,0,90,0,0,0,0,0"; }

Please Log in to join the conversation.

Time to create page: 0.093 seconds
Powered by Kunena Forum