Overview
Examples
Screenshots
Comparisons
Applications
Download
Documentation
Tutorials
Bazaar
Status & Roadmap
FAQ
Authors & License
Forums
Funding Ultimate++
Search on this site
Search in forums












SourceForge.net Logo
Home » Community » U++ community news and announcements » DarkTheme function parameters changed
Re: DarkTheme function parameters changed [message #60902 is a reply to message #60901] Mon, 07 October 2024 00:26 Go to previous messageGo to previous message
mirek is currently offline  mirek
Messages: 14261
Registered: November 2005
Ultimate Member
Lance wrote on Sun, 06 October 2024 22:52
mirek wrote on Sun, 06 October 2024 15:37
That is not enough, look at this:

CtrlLib/ArrayCtrl.h:686

ArrayCtrl& EvenRowColor(Color paper = Blend(SColorMark, SColorPaper, 220), Color ink = SColorText);

Please educate me if I am wrong.

What are SColorMark, SColorPaper, SColorText? Are they some Color variable in ArrayCtrl's Chameleon Style?

When a user code called
    EvenRowColor();

Something like this happen (conceptually)
   push ink = SColorText;
   push paper = Blend(SColorMark, SColorPaper, 220)
   push this
   call ArrayCtrl::EvenRowColor

If SColorText, SColorMark, SColorPaper are all refreshed after the theme change, EvenColor should receive correct color parameters.

So if instead of store a copy of SColorxxx(), let it store a reference/pointer of SColorxxx() instead. And all SColorXXX() should return Color& instead of Color.

Will this be adequate?


It could easily be a reference, but it does not solve the problem, unless you add somewhat complicate mechanism where the "Blend" part is somehow encoded. I mean, you can make SColorMark work, SColorPaper work, but what is actually stored is some other color, a mix of those two.

It is too clumsy and 'undefined' IMO for the rapid development.

Mirek
 
Read Message
Read Message
Read Message
Read Message
Read Message
Read Message
Read Message
Read Message
Read Message
Read Message
Read Message
Read Message
Read Message
Read Message
Read Message
Read Message
Read Message
Read Message
Read Message
Read Message
Read Message
Read Message
Read Message
Read Message
Read Message
Read Message
Read Message
Read Message
Read Message
Read Message
Read Message
Read Message
Read Message
Read Message
Read Message
Read Message
Previous Topic: SetRect "MegaRect" support...
Next Topic: 2024rc
Goto Forum:
  


Current Time: Sun Jun 08 15:06:38 CEST 2025

Total time taken to generate the page: 0.04340 seconds