> It's much simpler to implement one custom drawing function for a control,
> then to map to various themed widgetsets. The LCL took the difficult and
> more complex approach. Other people can contribute custom drawn controls. I
> wonder, why there is not already a package providing some custom drawn
> controls as there are so many for Delphi.
Well most of my visual components are actually custom drawn since they are
designed to implement stuff that GTK doesn't normally do. Where themes fall
short is in going one level up as it were. A quick google will find you at
least twenty delphi components for doing more advanced pop-up hints with for
example, depending on what you are looking for (everything from bubble-shaped
to extensive html with image support is available) - THAT is where custom
drawing becomes usefull, for adding that which gives your program an edge.
Sure you don't NEED bubble-shaped pop-ups but they are more pleasing to users
than square lines, and in fact they are becoming the default in several
development environments (on windows anyway).
As far as I can tell, there is no way to implement this with a theme - you
need some form of custom drawing to do it, and I don't think it can be said
that this in any way detracts from usability.
Several usability studies have come to the same conclusion, the universal look
and feel is a myth - icons and colours only have meaning in the culture from
which they originate - in other cultures they could mean completely different
things or more commonly nothing at all - the core thing a programmer MUST do
for usability is be consistent -always use the SAME file open icon, so users
can recognise it even if it DOESN'T mean anything to them.
The second most important thing is to ensure that your interface makes the
purpose of every element obvious right from the start, the more obvious you
can make things the easier it is to "get" the program.
The third rule is - make it look pretty.
Rule 1 says - uses themeing almost all the time.
Rules 2 and 3 says - override the theme if you have to.
Mind you lazarus does not at present provide a clean way of SETTING theme
style properties, and I think it will be very hard to add since the nature of
this will be platform independent (I highly doubt that the same themeing
structure would work on windows that works on GTK and even between GTK1 and
GTK2 there are huge differences in the theme files).
What would be good is if we can create a set of generic theme-style specifiers
for the LCL (much like we translated widgets) which are added as ADDITIONAL
properties, not replacing the delphi properties but being added as extras.
This way you can set at least those elements which are common to all
platforms in the IDE and it will follow a theme file on how to actually
implement them, but when there is a good reason, you use the delphi style
properties to override the them.
A side effect is that if it can also translate to CSS properties it would be a
very nice tool one day when CGI-from-the-IDE starts to become visual :)
>
> > When I say : live its not so simple, I think: nobody know all aspect and
> > environment of every program. One tools never be enough good to use in
> > any case.
>
> Sure, but we try. :)
Lol, that is why there isn't one programming language to rule them all :) but
OP comes pretty close.
--
"there's nothing as inspirational for a hacker as a cat obscuring a bug
by sitting in front of the monitor" - Boudewijn Rempt
A.J. Venter
Chief Software Architect
OpenLab International
www.getopenlab.com
www.silentcoder.co.za
+27 82 726 5103
_________________________________________________________________
To unsubscribe: mail [EMAIL PROTECTED] with
"unsubscribe" as the Subject
archives at http://www.lazarus.freepascal.org/mailarchives