Url of builtin image from custom css

Post here questions and problems related to oXygen frameworks/document types.
Patrik
Posts: 280
Joined: Thu Nov 28, 2013 9:32 am
Location: Hamburg/Germany
Contact:

Url of builtin image from custom css

Post by Patrik »

Hi,

within my custom css files I'd liketo be able to refer to some builtin images like 'editContent.gif'. But I can't know where the custom framework will be located relative to the oxygen folder so I can't use a relative path. Is there any way to use something like url('${OXYGEN_INSTALL}/lib/oxygen.jar/images/editContent.gif')?

If not, would it be ok to just copy the required images to an image folder in my custom framework? It will be shared as open source.

Patrik
Radu
Posts: 9470
Joined: Fri Jul 09, 2004 5:18 pm

Re: Url of builtin image from custom css

Post by Radu »

Hi Patrik,

You can try in the CSS's an URL which starts with "/" like:

Code: Select all

 url('/images/editContent.gif')
That should force the image to be resolved to the main Oxygen JAR.
But we do not consider that these image file names are API so at some point in the future we might change the file names, for example save the image as PNG instead of ".gif".
So maybe it would be better if you would copy that image from the JAR to your framework and refer to it directly.

Regards,
Radu
Radu Coravu
<oXygen/> XML Editor
http://www.oxygenxml.com
Patrik
Posts: 280
Joined: Thu Nov 28, 2013 9:32 am
Location: Hamburg/Germany
Contact:

Re: Url of builtin image from custom css

Post by Patrik »

Hi Radu,

thanks for the quick answer. Using an URL starting with '/'did not work. He was looking fot the file 'C:/images/editContent.gif'. So I copied the required images into my framework. (Just wasn't sure if there are any copyright issues with your images.)

Patrik
Radu
Posts: 9470
Joined: Fri Jul 09, 2004 5:18 pm

Re: Url of builtin image from custom css

Post by Radu »

Hi Patrik,

As long as you are using the image with an Oxygen framework there are not copyright issues.

Regards,
Radu
Radu Coravu
<oXygen/> XML Editor
http://www.oxygenxml.com
Post Reply