11from gi .repository import Pango
22
3+ second_row_gremlin_buttons = False
4+ show_toolinfo_on_main_page = True
5+
36# reduce size of v-buttons
47self .widgets ["vbtb_main" ].set_size_request (78 , - 1 )
58self .widgets ["lbl_time" ].hide ()
3134# second row for gremlin buttons
3235self .widgets ["box_gremlin_buttons" ].remove (self .widgets ["tbtn_view_dimension" ])
3336self .widgets ["box_gremlin_buttons" ].remove (self .widgets ["tbtn_view_tool_path" ])
34- self .widgets ["box_gremlin_buttons" ].remove (self .widgets ["btn_delete_view" ])
35- self .widgets ["btn_zoom_out" ].set_margin_end (0 )
36- hbox_gremlin_buttons_2 = Gtk .Box (orientation = Gtk .Orientation .HORIZONTAL )
37- hbox_gremlin_buttons_2 .show ()
38- hbox_gremlin_buttons_2 .pack_end (self .widgets ["btn_delete_view" ], False , False , 0 )
39- hbox_gremlin_buttons_2 .pack_end (self .widgets ["tbtn_view_tool_path" ], False , False , 0 )
40- hbox_gremlin_buttons_2 .pack_end (self .widgets ["tbtn_view_dimension" ], False , False , 0 )
41- self .widgets ["vbox15" ].pack_end (hbox_gremlin_buttons_2 , False , False , 3 )
37+ if second_row_gremlin_buttons :
38+ self .widgets ["box_gremlin_buttons" ].remove (self .widgets ["btn_delete_view" ])
39+ self .widgets ["btn_zoom_out" ].set_margin_end (0 )
40+ hbox_gremlin_buttons_2 = Gtk .Box (orientation = Gtk .Orientation .HORIZONTAL )
41+ hbox_gremlin_buttons_2 .show ()
42+ hbox_gremlin_buttons_2 .pack_end (self .widgets ["btn_delete_view" ], False , False , 0 )
43+ hbox_gremlin_buttons_2 .pack_end (self .widgets ["tbtn_view_tool_path" ], False , False , 0 )
44+ hbox_gremlin_buttons_2 .pack_end (self .widgets ["tbtn_view_dimension" ], False , False , 0 )
45+ self .widgets ["vbox15" ].pack_end (hbox_gremlin_buttons_2 , False , False , 3 )
4246
4347# reorder settings page
44- self .widgets ["vbox_window" ].remove (self .widgets ["frm_ntb_preview" ]) # "On Touch off"
45- self .widgets ["vbox_window" ].remove (self .widgets ["frm_keyboard" ])
46- self .widgets ["vbox_dro_settings" ].remove (self .widgets ["frm_preview" ])
4748self .widgets ["vbox_file" ].remove (self .widgets ["frm_message_position" ])
4849self .widgets ["vbox_file" ].remove (self .widgets ["frm_themes" ])
49- self .widgets ["vbox21" ].remove (self .widgets ["frm_unlock" ])
50- self .widgets ["vbox_window" ].pack_start (self .widgets ["frm_preview" ], False , False , 3 )
51- self .widgets ["vbox_dro_settings" ].pack_start (self .widgets ["frm_ntb_preview" ], False , False , 3 )
50+ self .widgets ["vbox_file" ].remove (self .widgets ["frm_gcodeview_font" ])
5251vbox_c1 = Gtk .Box (orientation = Gtk .Orientation .VERTICAL )
5352vbox_c2 = Gtk .Box (orientation = Gtk .Orientation .VERTICAL )
5453hbox_setup_appearance_2 = Gtk .Box (orientation = Gtk .Orientation .HORIZONTAL )
5554hbox_setup_appearance_2 .pack_start (vbox_c1 , False , False , 3 )
5655hbox_setup_appearance_2 .pack_start (vbox_c2 , False , False , 3 )
5756hbox_setup_appearance_2 .show ()
58- vbox_c1 .pack_start (self .widgets ["frm_keyboard" ], False , False , 3 )
5957vbox_c1 .pack_start (self .widgets ["frm_message_position" ], False , False , 3 )
58+ vbox_c1 .pack_start (self .widgets ["frm_gcodeview_font" ], False , False , 3 )
6059vbox_c2 .pack_start (self .widgets ["frm_themes" ], False , False , 3 )
61- vbox_c2 .pack_start (self .widgets ["frm_unlock" ], False , False , 3 )
6260vbox_c1 .show ()
6361vbox_c2 .show ()
6462label = Gtk .Label (label = _ ("Appearance" ) + " 2" )
7270
7371box_info = Gtk .Box (orientation = Gtk .Orientation .VERTICAL )
7472box_info .show ()
73+ if show_toolinfo_on_main_page :
74+ self .widgets .box_tool_and_code_info_2 .remove (self .widgets .box_tool_info )
75+ self .widgets .vbox15 .pack_start (self .widgets .box_tool_info , False , False , 0 )
76+ self .widgets .lbl_toolinfo_gcodes .set_text ("G-codes" )
7577box_info .pack_start (self .widgets ["box_tool_and_code_info" ], False , False , 0 )
7678box_info .pack_end (self .widgets ["hbox_main_info" ], False , False , 0 )
7779self .widgets ["ntb_user_tabs" ].append_page (box_info , Gtk .Label ("Info" ))
8890self .widgets .adj_x_pos .set_value (self .xpos )
8991self .widgets .adj_y_pos .set_value (self .ypos )
9092self .widgets .adj_width .set_value (self .width )
91- self .widgets .adj_height .set_value (self .height )
93+ self .widgets .adj_height .set_value (self .height )
94+ self .widgets .adj_jog_box_width .set_value (300 )
95+ self .widgets .vbx_jog .set_size_request (self .widgets .adj_jog_box_width .get_value (), - 1 )
0 commit comments