Besides scrolling-related issues, rev 5464 takes another step towards 
eliminating all problematic calls to w.setStyleSheet.

It does this by honoring focus-border settings in preference to 
background/foreground colors in text widgets.  This will happen if @bool 
use_focus_border = True This is the default, so by default you will get the 
new scheme.

**Important**: you can still specify colors for text widgets in the Qt 
style sheet as always, so don't panic ;-)  The new scheme simply means that 
if you allow focus border colors, only focus borders will be redrawn when 
focus changes *or* when input state changes from, say, insert state to 
command state.

Because the focus borders are updated without using w.setStyleSheet in any 
way, the new way will completely eliminate the unwanted scrolling that 
results from calls to w.setStyleSheet.

Furthermore, using focus borders colors should work well with *any* color 
scheme, including solarized colors.  But the color scheme I prefer and 
recommend is simply to use a white or sepia background in the body pane.  
Imo using strong border colors to indicate state is much better than using 
subtly-different pastel shades for the text background.  Ymmv.

Some new settings are needed to make the new scheme work.  They are in 
leoSettings.leo.

    @color focus_border_color = blue
    @color focus_border_command_state_color = red
    @color focus_border_overwrite_state_color = green

The first setting is not new, but iirc, the old default value for the first 
setting was red.  Naturally, you should copy these to myLeoSettings.leo if 
you change them.

I think most people will enjoy the new scheme.  It is much more solid than 
the old.  No unwanted scrolling ever.

Please report any problems with the new code immediately.

Edward

-- 
You received this message because you are subscribed to the Google Groups 
"leo-editor" group.
To view this discussion on the web visit 
https://groups.google.com/d/msg/leo-editor/-/Z6B62gLeOKwJ.
To post to this group, send email to [email protected].
To unsubscribe from this group, send email to 
[email protected].
For more options, visit this group at 
http://groups.google.com/group/leo-editor?hl=en.

Reply via email to