View Full Version : Different Skins for same component
patobelardo
09-07-2006, 04:35 AM
Hello, I am wanting to make a skin for the main bar of menu of the principal screen, and soon all the other screens to use another skin in the menu bar of these.
How could do this?
Thank you very much!
jstretch
09-07-2006, 05:30 AM
Read Chapter 31 - Designing Custom Components, also check out the Designers Guide which is only 2 chapters.
jstretch
09-07-2006, 05:35 AM
http://www.laszlosystems.com/lps-3.3/docs/component-design/index.html
patobelardo
09-07-2006, 05:47 AM
Thank you very much jstretch.
I need, in a same canvas, to have 2 skins for a same component, for example, in same canvas it wanted to have a rounded button and another button, totally different to first.
My problem is that I have a single folder by component, in $LPS_HOME/lps/components/.
This is possible?
Sorry by these newbie questions , but I am new in OpenLaszlo and I have not found the solution in the manual.
Thanks!
jstretch
09-07-2006, 06:06 AM
You do not need to modify the actual component in lz/components. Instead, you can subclass it:
<class name="myButton" extends="button">
//define look, feel, and functions
</class>
<class name="myButton2" extends="button">
//define look, feel, and functions
</class>
<myButton />
<myButton2 />
Does this help?
patobelardo
09-07-2006, 06:10 AM
Excelent jstretch!.
I will prove if I can create skins to the inherited classes, but believe that we are near the solution.
Thank you very much by the aid!
vBulletin® v3.8.4, Copyright ©2000-2012, Jelsoft Enterprises Ltd.