[Gambas-devel] Stock class

Fabien Bodard sirfabien at ...176...
Thu Jul 20 00:58:51 CEST 2006


Le Mercredi 19 Juillet 2006 23:37, Benoit Minisini a écrit :
> Sorry guys, I can't use the mailing-lists at the moment as my IP SMTP
> server was black-listed!
>
> I plan to implement the Stock class in another way as it is currently, so
> that it is as transparent as possible for the user:
>
> * PictureStock[Name, Size] must returns a picture according to a
> standardized name. A size can be specified.
>
> The standardized name could be "type/name.png".
>
> If the specified icon does not exist in the requested size, then an icon in
> another size scaled to the requested size must be returned.
>
> * PictureStock.All must return the names of all stock pictures.
>
> * PictureStock.Sizes must return a list of supported sizes.
>
> * PictureStock.Enabled to know if the stock is accessible.
>
> * PictureStock could be implemented in Gambas. The same code can be used by
> gb.qt and gb.gtk, like for the Action class.
>
> * The user do not have to use the Stock class directly. The Picture class
> will call the Stock class automatically when the picture path begins with
> ".stock/image".
>
> The idea behind that is that a stock should be able to store anything. As
> there is already a resource system in Gambas, by the use of relative paths,
> and that you cannot use hidden names in the IDE, then we could use them to
> reference "stock" resources that are not really stored in the project.
>
> Then I just have to add a tab to the icon file dialog in the IDE to allow
> the user using them.
>
> The last problem is how can I detect KDE icon paths in the QT component?
> Even if GTK+ has stock icons, GNOME seams to have more, I have the same
> question for it!

2 day to search that ... :/ but i've not found it !

the second problem is to get the current theme path !

I'm not sure that a pure gambas class will be sufficient ! as kde libs allow 
to implement theme effect too like the gnome libs.


> Regards,




More information about the Devel mailing list