Just the problem is that my style sheet is not predefined.
I want to generate a style sheet depending on settings in my application.
This generated stylesheet must be stored in the database as a TEXT-field or stored as a style using application.getNewUUID() + ‘.css’ as a style but this must be done within script.
The stylesheet will be regenerated several times, so styles must be updated as well by script.
there is no solutionmodel support for styles yet so what you want will not work.
Do remember if we would add support for altering or setting a style then that will only be reflected when forms are recreated and with a style
you alter a lot of forms at once so all those if they are already shown will not be updated.
I would like to make some template stylesheet (template.css)
On my forms I would like to link elements to this stylesheet
On runtime I would like to generate a stylesheet that will have the same contents as my template.
And I thought after application.overrideStyle(‘template.css’, ‘xxxxxxx-xxxx-xxxx-xxxx-xxxxxxxxxx.css’) then the wanted stylesheet would be used.
I need this because I have a standard webshop, which is used for different companies and these companies can change their styles and colors themselves without the need of a developer.
So the above sitiuation would be great to handle this
Would it be possible in the near future to add this functionality?
Shall I make a request or is there no chance that this will be implemented?
Perhaps a third parameter boolean OverwriteAllowed
Because I need possibility to overwrite a previous generated stylesheet, but others will not like that
If OverwriteAllowed = false, then createStyleSheet should return false if there is already a stylesheet with that name
I guess there will also be a method to delete a stylesheet?
What is the used for that?
Then all forms using that style are unresolved on the style properties?
also i was talking about newStyle(name,content)
so if you do one with an existing name it will throw an exception.
we could add a method setStyleContent(name,content) which updates an existing one. (and if you want to delete just use an empty content )
What is the used for that?
Then all forms using that style are unresolved on the style properties?
also i was talking about newStyle(name,content)
so if you do one with an existing name it will throw an exception.
we could add a method setStyleContent(name,content) which updates an existing one. (and if you want to delete just use an empty content )
These styles are for webshops. If a webshop is deleted then the corresponding style can be deleted also.
And remember that my forms will link to the template stylesheet and not to the new generated style sheet.
I hope the properties are not overwritten on the forms when I do application.overrideStyle()
Of couse my template style sheet will not be deleted. In that case you get unresolved of course.
setStyleContent(name,content) is good for updating.
And if I can test if a style exists, then I got all I need. I don’t like exceptions