Using Placeholders for "CSS Styles" in "Draw Cloner"

Special forum to share and discuss skins for Pano2VR and Object2VR
Post Reply
User avatar
studio360.com.ua
Posts: 18
Joined: Mon Mar 13, 2023 5:01 pm
Location: Ukraine
Contact:

Hello,

In the comments (placeholder $(uo)) for each node, I specified CSS styles:
1.png
1.png (541.12 KiB) Viewed 6483 times
2.png
2.png (513.07 KiB) Viewed 6483 times
In the skin, under the "Draw Cloner" settings, I added a "Draw Rectangle." For the "Draw Rectangle" styles, I used $(uo):
4.png
4.png (111.38 KiB) Viewed 6483 times
If this functionality worked correctly, I would get the following result:
6.png
6.png (291.33 KiB) Viewed 6483 times
However, it is currently impossible to pass CSS to the skin using any placeholder. As a result, I get the default color:
5.png
5.png (352.02 KiB) Viewed 6483 times
My question, which is mainly directed at the developers, is: How can I achieve the desired result? I want each "Draw Rectangle" to have its own color, which I specify using CSS styles.

Please note that the number of nodes changes depending on the project, which is why I use "Draw Cloner." This is important to me because I can create individual colored circles myself, but I need this functionality to work dynamically.
Windows 11 22H2, Pano2vr 7.1.9 64bit, Object2vr pro 3.1.10 64bit, Object2vr4.0beta 64bit
User avatar
Hopki
Gnome
Posts: 13436
Joined: Thu Jan 10, 2008 3:16 pm
Location: Layer de la Haye, Essex UK
Contact:

Hi,
You would add the styles into the skins CSS Style Sheet.
Then you can use the Style logic block to select which CSS Classes you need.
Using Tags, you can then change the CSS Classe in the button.
Regards,
Attachments
css_project.zip
(24.25 KiB) Downloaded 133 times
Garden Gnome Support
If you send an e-mail to support please send a link to the forum post for reference.
support@ggnome.com
https://ggnome.com/wiki/documentation/
User avatar
studio360.com.ua
Posts: 18
Joined: Mon Mar 13, 2023 5:01 pm
Location: Ukraine
Contact:

Thank you for taking the time to create the example. The idea is good. But at the moment, I have about 200 cars, and each has 3 to 7 interior colors. On the website, I use one skin (player created with the skin) for all projects. This means I would need to create between 600 and 1400 style classes in it. This is very inconvenient. I want to create a universal skin, where I can specify the style directly when creating the virtual tour, without making changes to the skin itself. But if I can't find a more optimal solution, I will have to use your idea.

PS: In krpano, this is somehow implemented without classes. Maybe there’s a way to do the same here.
example.png
example.png (2.03 MiB) Viewed 6421 times
Windows 11 22H2, Pano2vr 7.1.9 64bit, Object2vr pro 3.1.10 64bit, Object2vr4.0beta 64bit
Post Reply