@@ -40,7 +40,7 @@ class TkintermdFrame(tk.Frame):
40
40
def __init__ (self , master , ** kwargs ):
41
41
tk .Frame .__init__ (self , master ) # no need for super
42
42
43
- logger = log .create_logger ()
43
+ self . logger = log .create_logger ()
44
44
45
45
# Toolbar.
46
46
self .top_bar = tk .Frame (self .master )
@@ -121,7 +121,7 @@ def __init__(self, master, **kwargs):
121
121
# test them for compatability
122
122
self .load_style (style_name )
123
123
except Exception as E :
124
- logger .exception (f"WARNING: style { style_name } failed ({ E } ), removing from style menu." )
124
+ self . logger .exception (f"WARNING: style { style_name } failed ({ E } ), removing from style menu." )
125
125
continue # don't add them to the menu
126
126
# add the rest to the menu
127
127
self .style_menu .add_command (
@@ -133,7 +133,7 @@ def __init__(self, master, **kwargs):
133
133
134
134
# Set Pygments syntax highlighting style.
135
135
self .lexer = Lexer ()
136
- self .syntax_highlighting_tags = self .load_style ("stata " )
136
+ self .syntax_highlighting_tags = self .load_style ("monokai " )
137
137
# Default markdown string.
138
138
default_text = constants .default_md_string
139
139
self .text_area .insert (0.0 , default_text )
@@ -180,26 +180,26 @@ def popup(self, event):
180
180
"""
181
181
self .right_click .tk_popup (event .x_root , event .y_root )
182
182
183
- def on_scrollbar (self , * args ):
184
- """Scrolls the text area scrollbar when clicked/dragged with a mouse.
183
+ # def on_scrollbar(self, *args):
184
+ # """Scrolls the text area scrollbar when clicked/dragged with a mouse.
185
185
186
- - Queries and changes the vertical position of the text area view.
187
- """
188
- self .text_area .yview (* args )
189
- # # This links the scrollbars but is currently causing issues.
190
- # self.preview_area.html.yview(*args)
191
-
192
- def on_mousewheel (self , * args ):
193
- """Moves the scrollbar and scrolls the text area on mousewheel event.
186
+ # - Queries and changes the vertical position of the text area view.
187
+ # """
188
+ # self.text_area.yview(*args)
189
+ # # # This links the scrollbars but is currently causing issues.
190
+ # # self.preview_area.html.yview(*args)
191
+
192
+ # def on_mousewheel(self, *args):
193
+ # """Moves the scrollbar and scrolls the text area on mousewheel event.
194
194
195
- - Sets the fractional values of the slider position (upper and lower
196
- ends as value between 0 and 1).
197
- - Calls `on_scrollbar` function.
198
- """
199
- self .scrollbar .set (* args )
200
- # # This links the scrollbars but is currently causing issues.
201
- # self.preview_area.vsb.set(*args)
202
- self .on_scrollbar ('moveto' , args [0 ])
195
+ # - Sets the fractional values of the slider position (upper and lower
196
+ # ends as value between 0 and 1).
197
+ # - Calls `on_scrollbar` function.
198
+ # """
199
+ # self.scrollbar.set(*args)
200
+ # # # This links the scrollbars but is currently causing issues.
201
+ # # self.preview_area.vsb.set(*args)
202
+ # self.on_scrollbar('moveto', args[0])
203
203
204
204
def select_all (self , * args ):
205
205
"""Select all text within the editor window.
0 commit comments