I tried everything you wrote, but still no luck. When I view the source I can
see that theme.resource is set as my apptheme, but icons are still old : (((
I have also tried to change original images.properties - still nothing.
Maybe this approach worked in 4.2?
Can someone tell me how this theme-stuff works? How does SJSAS collect
images, and how are they interpreted on client?
richard ratta wrote:
>
> To change an image reference (if it not referenced in a CSS file) you
> can always define
> application level theme properties that override the images referenced
> in the "theme".
>
> See
>
> http://webdev2.sun.com/woodstock-theme-doc/index.html
>
> For all the gory details.
>
> But basically in your web.xml define the THEME_RESOURCES init param
>
> <context-param>
> <param-name>com.sun.webui.theme.THEME_RESOURCES</param-name>
> <param-value>theme.apptheme</param-value>
> </context-param>
>
> Define properties in a file "WEB-INF/classes/theme/apptheme.properties"
> And a javascript file "WEB-INF/classes/theme/nls/apptheme.js".
>
> The properties are documented in the above document.
> The properties are defined in
> "themes/src/suntheme/properties/images.properties" in the source tree or
> "com/sun/webui/woodstock4_3/suntheme/properties/images.properties" in
> the jar.
>
> You can see these in a browser in any Woodstock application by
>
> http://<containerhost and
> port>/<appcontext>/theme/com/sun/webui/woodstock4_3/suntheme/properties/images.properties
>
> or any other theme file, as long as the ThemeServlet context path is
> "theme". Note that this is for
> the latest source base earlier releases use "sunthemeM_N" vs
> "woodstock4_3". Just look in any
> application web page to see the path or dump the jar.
> (and any of the other properties files, "styles.properties",
> "javascript.properties", etc.
>
> Say you want to change a tree image.
>
> TREE_LINE_VERTICAL=_at_THEME_PATH@/images/tree/tree_linevertical.png
> TREE_LINE_VERTICAL_MAP=COMBINED_IMAGE_MAP
> TREELINE_VERTICAL_HEIGHT=22
> TREE_LINE_VERTICAL_WIDTH=16
>
> You add the following to "WEB-INF/classes/theme/apptheme.properties"
>
> TREE_LINE_VERTICAL=/theme/images/thicktreelinevertical.png
> TREE_LINE_VERTICAL_MAP=
> TREELINE_VERTICAL_HEIGHT=22
> TREE_LINE_VERTICAL_WIDTH=16
>
> And in the "WEB-INF/classes/theme/nls/apptheme.js" file
>
> {
> "images" : {
> "TREE_LINE_VERTICAL" : "/theme/images/thicktreelinevertical.png",
> "TREE_LINE_VERTICAL_MAP : "",
> "TREELINE_VERTICAL_HEIGHT" : "22",
> "TREE_LINE_VERTICAL_WIDTH" : "16"
> }
> }
>
> You can do this for any theme property even the with javascript files
> and stylesheets.
> Javascript and stylesheets will not replace the theme's stylesheets and
> javascript files but
> will be included in every page. See the refrenced document for details.
>
> The thing to note is that the resources must appear under
> "WEB-INF/classes" because
> that is where the "ThemeServlet" will find theme.
>
> -rick
>
> Goran Milinovic wrote:
>
>>Thanks for quick reply!
>>
>>I don't have "build-combineImages" in build.properties, so I've added it
>>with argument "no". None combination work. I tried build-combineImages=no,
>>build-combineImages=false, build.combineImages=no,
>>build.combineImages=false, ... Nothing : ((
>>
>>But there is some pattern: tree_handlerighttop.png, tree_handledowntop.png
>>and all the lines (tree_linelastnode, tree_linefirstnode,
>>tree_linemiddlenode, tree_linevertical - which I erased in Photoshop) are
>>always displayed correctly. Other 4 images always displays incorrectly.
>>
>>I don't get it. Where does this 4 bad images come from when I have
>>overwritten all webui-jsf-suntheme.jar files. I have searched for any of
>>those bad images on hard, even in package files, and nothing. Where does
>>Netbeans (or maybe Sun Java System Application Server) store files? Some
>>cache maybe??
>>
>>Is there any way to change default theme (web) for Netbeans 6.1? How can I
>>see the path of deployed files?
>>
>>P.S. Deep, I can send you *.war if you need this 'example-bug' code for
some
>>testing-corrections.
>>
>>Thanks a lot..
>>Goran
>>
>>
>>Ratnadeep Bhattacharjee-2 wrote:
>>
>>
>>>This is indeed very strange. One of the optimizations we did in
>>>Woodstock was to generate a combined image map of all the images that
>>>are needed by the components. On the client side the right image is
>>>selected from that combined image map at run time. I am not sure if that
>>>has anything to do with what you are seeing. When you are rebuilding
>>>themes can you turn off that feature and see if the problem goes away?
>>>In build.properties set "build-combineImages" to "no".
>>>
>>>Thanks,
>>>-Deep.
>>>
>>>
>>>Goran Milinovic wrote:
>>>
>>>
>>>>Hi,
>>>>I'm currently working on some web project and one of my tasks is to
>>>>customize webuijsf:tree. The thing I wanted to do is to change handle
>>>>images
>>>>(little arrows on the left of the tree nodes which are pointed on the
>>>>right
>>>>when tree node is closed, and down when it's opened).
>>>>
>>>>First, I tried simply to overwrite images that represents those arrows
>>>>(maintaining file names) in webui-jsf-suntheme.jar. It worked perfectly
>>>>in
>>>>Netbeans 6.0, but when I switched to 6.1 everything started acting weird
>>>>(of
>>>>course, for new netbeans I modified new webui-jsf-suntheme.jar in the
>>>>same
>>>>way). Problem is that only first arrow is new one, rest are from
original
>>>>theme - example in images bellow.
>>>>
>>>>http://www.nabble.com/file/p16763506/closed.jpg
>>>>http://www.nabble.com/file/p16763506/open.jpg
>>>>
>>>>I have used jar file from its original location (x:\program
>>>>files\netbeans
>>>>6.1\visualweb2\modules\ext\webui-jsf-suntheme.jar). When I build the
>>>>project, build folder contained new-changed version of
>>>>webui-jsf-suntheme.jar (the one I need).
>>>>
>>>>I even overwrote all webui-jsf-suntheme.jar on my harddrive with new
>>>>version, and still nothing.
>>>>Tried to clear browser cache - you guess: nothing!
>>>>Checked every image (tree_handledownlast, tree_handledownmiddle,
>>>>tree_handledowntop, tree_handledowntopns, tree_handlerightlast,
>>>>tree_handlerightmiddle, tree_handlerighttop, tree_handlerighttopns) and
>>>>all
>>>>of them are NEW.
>>>>
>>>>Tried to deploy app in IE7, FF2.0.0.13, Safari 3.1 = all act the same -
>>>>wrong.
>>>>IE6 shows new images but layout is mixed up.
>>>>
>>>>Don't know if this is a bug, or maybe I missed somthing.
>>>>I'm using Netbeans 6.1 rc1, Sun Java System Application Server 9.1 u1.
>>>>
>>>>Has anyone tried something like this?
>>>>Is there any cache folder for SJSAS 9.1 u1, or maybe Netbeans?
>>>>
>>>>Thanks a lot!
>>>>Goran
>>>>
>>>>
>>>>
>>>>
>>>---------------------------------------------------------------------
>>>To unsubscribe, e-mail: dev-unsubscribe_at_woodstock.dev.java.net
>>>For additional commands, e-mail: dev-help_at_woodstock.dev.java.net
>>>
>>>
>>>
>>>
>>>
>>
>>
>>
>
> ---------------------------------------------------------------------
> To unsubscribe, e-mail: dev-unsubscribe_at_woodstock.dev.java.net
> For additional commands, e-mail: dev-help_at_woodstock.dev.java.net
>
>
>
--
View this message in context: http://www.nabble.com/Modifying-Web-UI-Default-Theme-images-tp16763506p16834673.html
Sent from the Project Woodstock - Dev mailing list archive at Nabble.com.