Home » U++ Library support » U++ Library : Other (not classified elsewhere) » why not state oriented?
why not state oriented? [message #19905] |
Sat, 31 January 2009 15:18  |
 |
amando1957
Messages: 57 Registered: November 2007 Location: Wien/Vienna/Viden
|
Member |
|
|
Hi to all!
In the manual about Draw I've read the *state oriented* approach were not reality here, you devs will rather prefer args instead (alike with FileOut the put32le() etc.).
I always have considered the states less cumbersome, and it results in a less number of args.
I will often call the paintLine() a lot of times, but the lines are always blue and have 4 pixels, then I can surround a rect with the same one.
Setting a var of my class I have always a "current state", hardly to avoid.
At the Apple you set a pen you can use subsequent, until you set a new one again. The "graphics context", as they call it, is treatened similar. Thats basically like at WIN-GDI (though these two systems have obvious differences for devs).
At the Apple they are also not starters there, so it seems a question of taste.
What is the advantage of using args instead?
OK, I'm spared of calling set-get-functions all the time, thats one thing after all, so the one call will do in some cases.
Martin
|
|
|
Goto Forum:
Current Time: Sat Jun 28 14:33:33 CEST 2025
Total time taken to generate the page: 0.03365 seconds
|