How to change Pythonwin background colour? 
Author Message
 How to change Pythonwin background colour?

I need to change Pythonwin's background colour from bright white. I've
managed to change a lot of it through the colour configuration options
but not the interactive window.

regards,

rhys



Mon, 24 Nov 2003 03:11:03 GMT  
 How to change Pythonwin background colour?

Quote:

> I need to change Pythonwin's background colour from bright white. I've
> managed to change a lot of it through the colour configuration options
> but not the interactive window.

I'm afraid it can not be done short of hacking the code.

Mark.



Mon, 24 Nov 2003 07:37:50 GMT  
 How to change Pythonwin background colour?

Quote:


> > I need to change Pythonwin's background colour from bright white. I've
> > managed to change a lot of it through the colour configuration options
> > but not the interactive window.

> I'm afraid it can not be done short of hacking the code.

> Mark.

Mark,

Thank you for your reply.

I attended your presentation at the accu conference and and am following
your (excellent;) book.

This is a real problem for me as I have a sensitivity to bright light.
I've downloaded the Pythonwin source - is it just a matter of finding
white_brush or something similar, changing it and recompiling?

regards,

rhys



Mon, 24 Nov 2003 08:18:24 GMT  
 How to change Pythonwin background colour?

Quote:

> This is a real problem for me as I have a sensitivity to bright light.
> I've downloaded the Pythonwin source - is it just a matter of finding
> white_brush or something similar, changing it and recompiling?

Open pywin.framework.interact

Find the following function:

        def SetStyles(self):
                FormatterParent.SetStyles(self)
                Style = pywin.scintilla.formatter.Style

You can add a 3rd param to the "Style()" function.  This is an RGB value
for the background.  Eg:

self.RegisterStyle( Style(STYLE_INTERACTIVE_EOL,
STYLE_INTERACTIVE_PROMPT, 8421504 ) )
self.RegisterStyle( Style(STYLE_INTERACTIVE_PROMPT, formatInput, 8421504 ) )

etc - note the 3rd param I added - this is win32api.RGB(128,128,128),
and gives a pretty horrible grey as the background color.  Add it to all
or any of the Style() calls you like.

If you want to generalize this somehow so the value is read from the
registry I would be happy to include if.  I may even get around to
adding it to the dialog so it can be specified.

Mark.



Mon, 24 Nov 2003 08:44:01 GMT  
 How to change Pythonwin background colour?

Quote:


> > This is a real problem for me as I have a sensitivity to bright light.
> > I've downloaded the Pythonwin source - is it just a matter of finding
> > white_brush or something similar, changing it and recompiling?

> Open pywin.framework.interact

> Find the following function:

>         def SetStyles(self):
>                 FormatterParent.SetStyles(self)
>                 Style = pywin.scintilla.formatter.Style

> You can add a 3rd param to the "Style()" function.  This is an RGB value
> for the background.  Eg:

> self.RegisterStyle( Style(STYLE_INTERACTIVE_EOL,
> STYLE_INTERACTIVE_PROMPT, 8421504 ) )
> self.RegisterStyle( Style(STYLE_INTERACTIVE_PROMPT, formatInput, 8421504 ) )

> etc - note the 3rd param I added - this is win32api.RGB(128,128,128),
> and gives a pretty horrible grey as the background color.  Add it to all
> or any of the Style() calls you like.

> If you want to generalize this somehow so the value is read from the
> registry I would be happy to include if.  I may even get around to
> adding it to the dialog so it can be specified.

> Mark.

Thank you.

rhys



Mon, 24 Nov 2003 13:40:42 GMT  
 
 [ 6 post ] 

 Relevant Pages 

1. VW2 Changing Background Colour

2. changing background colour of an rc_graphic window

3. Changing image background colour on canvas?

4. Changing background colour of BLT hiertable

5. C55 Internet & Background Colour

6. Background colour on graph

7. background colour for menus

8. Aqua menu background colour.

9. Setting image background colour in text widget?

10. can't make image and background colour match

11. AbtHtmlTableColumn: change colour of heading?

12. Changing colour of fields on reports.

 

 
Powered by phpBB® Forum Software