GCode viewer line numbers

  • persei8
  • persei8's Avatar Topic Author
  • Offline
  • Platinum Member
  • Platinum Member
More
13 Mar 2020 12:49 #160064 by persei8
GCode viewer line numbers was created by persei8
The current gcode_editor widget only allows a line number margin width of 5 characters. 2d carving files often have more than 100K lines. What's the best way to change this to 6 characters? Thanks.

Please Log in or Create an account to join the conversation.

More
13 Mar 2020 13:43 #160066 by bbsr_5a
Replied by bbsr_5a on topic GCode viewer line numbers
best way woudt be reduce the lines of g-code by increasing the linewidth
or even a greater Tool

this needs to be done as of a programmer in the QTWidget

Please Log in or Create an account to join the conversation.

More
13 Mar 2020 13:44 - 13 Mar 2020 17:40 #160067 by cmorley
Replied by cmorley on topic GCode viewer line numbers
I just pushed work - it should be one character wider now and if you want to change it after that then use something like this:

self.w.GCODEEDITOR_WIDGET_NAME.set_margin_width(8)

This is new so you need to pull it in before trying it.

Chris
Last edit: 13 Mar 2020 17:40 by cmorley.

Please Log in or Create an account to join the conversation.

More
13 Mar 2020 23:32 - 13 Mar 2020 23:42 #160124 by phillc54
Replied by phillc54 on topic GCode viewer line numbers

I just pushed work - it should be one character wider now and if you want to change it after that then use something like this:
self.w.GCODEEDITOR_WIDGET_NAME.set_margin_width(8)
This is new so you need to pull it in before trying it.

I don't see this yet.

Edit: I see it just got pushed to master with my last update.
Last edit: 13 Mar 2020 23:42 by phillc54.

Please Log in or Create an account to join the conversation.

More
13 Mar 2020 23:58 #160127 by cmorley
Replied by cmorley on topic GCode viewer line numbers
Thats twice now where I merged and then didn't push --getting older faster...

Please Log in or Create an account to join the conversation.

More
14 Mar 2020 00:28 #160133 by phillc54
Replied by phillc54 on topic GCode viewer line numbers

Thats twice now where I merged and then didn't push --getting older faster...

I know the feeling well...

Quick question, is it possible to set the color and background in the stylesheeteditor. I have tried a few things but didn't get anywhere.
I only need it for when I am trying different things and do something wrong they end up the same color.

Please Log in or Create an account to join the conversation.

More
14 Mar 2020 01:12 #160136 by cmorley
Replied by cmorley on topic GCode viewer line numbers
I haven't tried stylesheets on gcode editor - i'll see what i can findout. My guess is it's controlled by the editor because of text coloring for different code.

Please Log in or Create an account to join the conversation.

More
14 Mar 2020 01:25 #160137 by phillc54
Replied by phillc54 on topic GCode viewer line numbers
Not the GCode Editor (although that would be nice as well) the StyleSheetEditor itself.
Sometimes I change something in the StyleSheetEditor and end up with the same color and background...

Please Log in or Create an account to join the conversation.

More
14 Mar 2020 02:17 #160139 by cmorley
Replied by cmorley on topic GCode viewer line numbers
ok try this:
StyleSheetEditor, QTextEdit {
    background-color: lightblue;
	color:green;
}
The following user(s) said Thank You: phillc54

Please Log in or Create an account to join the conversation.

More
14 Mar 2020 02:31 #160142 by phillc54
Replied by phillc54 on topic GCode viewer line numbers
Thanks Chris, the QTextEdit without the StyleSheetEditor works well enough to keep me out of trouble.

Please Log in or Create an account to join the conversation.

Moderators: cmorley
Time to create page: 0.665 seconds
Powered by Kunena Forum