Image class and paths relative to classpath
Daniel Fuchs
daniel.fuchs at oracle.com
Tue Apr 24 03:27:31 PDT 2012
> Date: Tue, 24 Apr 2012 11:26:28 +0200
> From: Martin Sladecek <martin.sladecek at oracle.com>
> Subject: Re: Image class and paths relative to classpath
> To: openjfx-dev at openjdk.java.net
> Message-ID: <4F9671C4.7050107 at oracle.com>
> Content-Type: text/plain; charset=ISO-8859-1; format=flowed
>
Hi Martin,
> Hi Daniel,
> how is "@" notation different? As was already mentioned in the thread,
> "@/" searches through the classpath, so in FXML, there's already support
> for classpath search.
Right - I didn't think of that - I was speaking of relative paths using
the @ notation, things like "@resources/images/img.png" or
"@../../resources/images/img.png".
Such paths require no configuration at all - they are resolved against
the FXML file location.
> Anyhow, SB might choose not to support classpath search, if it's beyond
> it's capabilities.
Yes - that's what I meant: if you use absolute URL or paths relative
to the FXML file in your FXML, then SB will be able to deal with them.
If you use a classpath relative path - whether @/ or classpath:,
then it will depend on whether you've entered/set up the proper
configuration. In the developer preview - using classpath relatives
paths will not work - that's one of the preview limitations.
And (@Daniel) I'm not saying that I don't like the
classpath: URLs - They have the big advantage of making it clear
that the file must be looked up using the classpath :-)
cheers,
-- daniel
>
> -Martin
More information about the openjfx-dev
mailing list