Hello Zsolt,

Firstly, please post to the developer list rather than to me
personally. I'm not able to cater for private requests.

Thanks for the IRC log (below) of your chat to Jody and Andrea. I
don't think LocaleUtils is the way to go in this case since you are
talking about icons that are application specific, not country /
culture specific.

As you will have seen from Jira, this has been previously discussed
and the only reason it hasn't been done yet is that I haven't had the
time. However, if you and/or Jody would like to do a patch I will make
time to review it.

Michael


On 6 December 2011 18:32, Zsolt Sandor <[email protected]> wrote:
> Hello,
>
> We had a talk on #geotools about having customizable icons for pan/zoom/etc.
> tool, because the current solution is pretty hardcoded.
> I can acquire some time to do that, we eventually need this feature in our
> project.
>
> The idea was to make it work using the LocaleUtils. I paste the chat log we
> had yesterday, please comment, if you agree with
> the solution, or have a different solution in your mind.
>
> Thanks in advance,
>
>  Zsolti
>
> [15:48] <jgarnett> it is 1am and I am in testing mode here; so I may not be
> useful
> [15:49] <jgarnett> (the comment was basically - submit a patch :D I am sure
> we can teach the code to use your icons)
> [15:49] <me> http://svn.osgeo.org/geotools/trunk/
> [15:49] <me> where should i look for the swing code?
> [15:49] <me> org.geotools.swing.*
> [15:50] <me> i'd like basically check, what has been done in the most recent
> version, maybe it's already done
> [15:50] <jgarnett> in modules/unsupported/swing
> [15:50] <jgarnett> (it has not made it through QA yet)
> [15:51] <jgarnett>
> http://svn.osgeo.org/geotools/trunk/modules/unsupported/swing/src/main/java/org/geotools/swing/action/
> [15:51] <me> i am not surprised :)
> [15:51] <jgarnett> seems to have the actions; they grab their icon from the
> "tool"
> [15:51] <jgarnett>
> http://svn.osgeo.org/geotools/trunk/modules/unsupported/swing/src/main/java/org/geotools/swing/tool/
> [15:51] <me> okay, right now we are talking about
> http://svn.osgeo.org/geotools/trunk/modules/unsupported/swing/src/main/java/org/geotools/swing/tool/PanTool.java
> [15:51] <jgarnett> ah look it may of been done
> [15:52] <jgarnett>
> http://svn.osgeo.org/geotools/trunk/modules/unsupported/swing/src/main/java/org/geotools/swing/tool/ZoomInTool.java
> [15:52] <jgarnett> public static final String TOOL_NAME =
> LocaleUtils.getValue("CursorTool", "ZoomIn");
> [15:52] <jgarnett> so LocaleUtils has your independence - now to sort out
> how to customise it
> [15:52] <jgarnett>
> http://svn.osgeo.org/geotools/trunk/modules/unsupported/swing/src/main/java/org/geotools/swing/locale/
> [15:53] <me> i see, but it's just the name and tooltip
> [15:53] <jgarnett> And i tlooked up icon
> [15:53] <me> which is fine, but we need something like that for images
> [15:54] <jgarnett> or perhaps not ...
> [15:54] <jgarnett> ImageIcon imgIcon = new
> ImageIcon(getClass().getResource(CURSOR_IMAGE));
> [15:54] <jgarnett> okay
> [15:54] <jgarnett> so I would make a patch to LocaleUtils allowing it to
> lookup ImageIcon
> [15:54] <jgarnett> and submit it via the issue tracker
> [15:55] <me> is it the right place?
> [15:55] <me> i mean, locale is for localization. It has merely nothing to do
> with icons
> [15:55] <jgarnett> it is very common for internationalisation to cover both
> text
> [15:55] <jgarnett> and graphics
> [15:55] <aaime> agreed
> [15:55] <aaime> one symbol might have different meanings depending on the
> receiving culture
> [15:56] <jgarnett> as it is something that you want to externalise from the
> code
> [15:56] <jgarnett> and customise for different installations
> [15:56] <aaime> red is not "danger" or "attention" for everyone
>

------------------------------------------------------------------------------
Cloud Services Checklist: Pricing and Packaging Optimization
This white paper is intended to serve as a reference, checklist and point of 
discussion for anyone considering optimizing the pricing and packaging model 
of a cloud services business. Read Now!
http://www.accelacomm.com/jaw/sfnl/114/51491232/
_______________________________________________
Geotools-devel mailing list
[email protected]
https://lists.sourceforge.net/lists/listinfo/geotools-devel

Reply via email to