Home › Forums › Presentation › Styles › theme (not found?)
Tagged: theme
- This topic has 3 replies, 2 voices, and was last updated 5 years, 2 months ago by Jimmy T.
-
AuthorPosts
-
-
September 4, 2019 at 11:02 am #11938Jimmy TParticipant
I am wanting to add a logo to NexJ 9.x using a theme. I think I’m doing the same thing that I did with the training environment (which worked), but I can’t get it to work in another environment. Please see attached image “theme-folders.jpg” for the directory structure (I had to create the folders mod/images/g5, mod/themes). I was able to see in v8.x a splash screen logo that put in clarity/meta/icons/splash.jpg, so I at least know that I’m generally in the right directory structure.
g5.theme contains (which I just copied from a training example, adapted the paths):
# example1.theme
#/* Background */
color.prime=#0e4564
color.dark=#001e3a
color.light=#447092
color.back=#b0bec5
color.data=#ffffff
color.accent=#0091ea
color.action=#64c1ff
color.flash=#0064b7
color.media=#b0bec5
color.notice=#eceff1
color.error=#e53935
color.warning=#ffd600
color.info=#39b54acolor.1=#104076
color.2=#F00A6B
color.3=#60D0C3
color.4=#FF8409
color.5=#2962ff
color.6=#f06292
color.7=#80cbc4
color.8=#ce93d8
color.9=#b3e5fc
color.10=#ffb74d
color.11=#64b5f6
color.12=#f48fb1page.nav.image=url(images/g5/BGM-Logo-280×1366-2.png)
page.nav.image.open=url(images/g5/page-nav.open.png)
page.nav.color=white
page.nav.title.height=56pxThis results in an error (see attachment browser.jpg)
I get the same result if I reference a non-existent theme (ex: theme=g6), so I suspect that the server just cannot find g5 (futher confirmed by seeing an exception in the console log: “Unable to open the CSS resource “/themes/g5.theme”. (err.ui.web.resourceOpen)”. Is there anything else I need to do for the server to be able to find the theme?
Thanks.
0Attachments:
You must be logged in to view attached files. -
September 6, 2019 at 12:31 pm #12015Community ManagerKeymaster
Hi Jimmy,
Please find instructions below to setup the project to use themes. The developer documentation will be updated and published by next week.
Regards,
Dhruv
To enable working with themes, your project must be configured with the following settings.
In your .project file you need the javabuilder and javanature as seen below.
<pre class=”lang:xhtml decode:true “><?xml version=”1.0″ encoding=”UTF-8”?><projectDescription>
<name><projectName></name>
<comment></comment>
<projects>
</projects>
<buildSpec>
<buildCommand>
<name>org.eclipse.jdt.core.javabuilder</name>
<arguments>
</arguments>
</buildCommand>
<buildCommand>
<name>com.nexjsystems.nexjstudio.NexJBuilder</name>
<arguments>
</arguments>
</buildCommand>
</buildSpec>
<natures>
<nature>org.eclipse.jdt.core.javanature</nature>
</natures>
</projectDescription>
Additionally, you need the following in the .classpath file.
Create src folder in your project directory, then:
<pre class=”lang:xhtml decode:true”><?xml version=”1.0″ encoding=”UTF-8″?>
<classpath><classpathentry kind=”src” path=”mod”/>
<classpathentry kind=”src” path=”src”/>
<classpathentry kind=”con” path=”org.eclipse.jdt.launching.JRE_CONTAINER”/>
<classpathentry kind=”output” path=”bin”/>
</classpath>
0 -
September 6, 2019 at 2:14 pm #12025Jimmy TParticipant
Thanks; I shut down NexJ studio, edited the .project file, created a .classpath file and src folder in the same folder as .project file, restarted NexJ studio, started server console… and still the same result (“Unable to open the CSS resource “/themes/g5.theme”). Is there any other step required? I notice that in the training environment, the output folder (bin) conatins the themes folder (as well as app, images, mock, nexj folders), but in the clarity environment it does not (the bin folder only contains the folders env, meta, and the .project file).
0 -
September 13, 2019 at 10:10 am #12146Jimmy TParticipant
<tumbleweed rolls by>
0
-
-
AuthorPosts
- You must be logged in to reply to this topic.