You are viewing a plain text version of this content. The canonical link for it is here.
Posted to jetspeed-dev@portals.apache.org by Chris Kimpton <ki...@yahoo.com> on 2001/09/04 13:26:48 UTC
Additions to the skin class - anyone changing this?
Hi,
I want to add 2 more properties for skins
. TitleStyleClass
- to be used against the class attribute on the title of a portlet.
Lets you use those funky CSS formatting options
. ContentBackgroundColor
- to be used as the bgcolor for the innermost table containing the
content. This lets you do those thin line bordered portlets, by
giving the overall portlet a dark bgcolor and then setting this
bgcolor to be a lighter colour.
Is this ok? Anyone else doing anything similar? Any other requests?
I've just started looking at it, but it looks like I need to change
PortletSkin.java
BasePortletSkin.java
skins.xreg
jetspeed.vm
I'll send some patches later.
Regards,
Chris
=====
Need somewhere to Live in London - http://freeflats.com
__________________________________________________
Do You Yahoo!?
Get email alerts & NEW webcam video instant messaging with Yahoo! Messenger
http://im.yahoo.com
---------------------------------------------------------------------
To unsubscribe, e-mail: jetspeed-dev-unsubscribe@jakarta.apache.org
For additional commands, e-mail: jetspeed-dev-help@jakarta.apache.org
Re: Additions to the skin class - anyone changing this?
Posted by Dave Carlson <dc...@ontogenics.com>.
I vote for moving toward complete useof CSS. I already modified several of
the controls to use CSS, which fixes the problems you mention (at least on IE
5.5). It's quite easy: just replace use of
<td><font color="xxx">
with
<td style="color: xxx">
or something similar, depending on where the color style is applied.
Dave
----- Original Message -----
From: "Santiago Gala" <sg...@hisitech.com>
> Other thing that is misserably failing is that the way we apply skins
> interferes with the CSS applied, so the grey skin shows black text on
> black background for selected tab (under Mozilla at least). I think we
> should go either ofr a full CSS definition, thus using styles in the
> controls and controllers, or for a "conventional" skinning scheme, and
> stop using the CSS file.
>
---------------------------------------------------------------------
To unsubscribe, e-mail: jetspeed-dev-unsubscribe@jakarta.apache.org
For additional commands, e-mail: jetspeed-dev-help@jakarta.apache.org
Re: Additions to the skin class - anyone changing this?
Posted by Chris Kimpton <ki...@yahoo.com>.
Hi,
> Try to send your patches as attachments, since the word wrapping of
> the mailer spoils them.
No problem.
>
> Other thing that is misserably failing is that the way we apply
> skins
> interferes with the CSS applied, so the grey skin shows black text
> on
> black background for selected tab (under Mozilla at least). I think
> we
> should go either ofr a full CSS definition, thus using styles in
> the
> controls and controllers, or for a "conventional" skinning scheme,
> and
> stop using the CSS file.
>
> Oppinions on this one?
>
It seems to me that the CSS route is the way to go - more style
options available that way.
Chris
=====
Need somewhere to Live in London - http://freeflats.com
__________________________________________________
Do You Yahoo!?
Get email alerts & NEW webcam video instant messaging with Yahoo! Messenger
http://im.yahoo.com
---------------------------------------------------------------------
To unsubscribe, e-mail: jetspeed-dev-unsubscribe@jakarta.apache.org
For additional commands, e-mail: jetspeed-dev-help@jakarta.apache.org
Re: [PATCH] added some css classes to jetspeed.vm and jetspeed-tab.vm
Posted by Chris Kimpton <ki...@yahoo.com>.
Hi,
>
> Applied. I changed jetspeed-tab.vm so that it uses style="color:
> ..." in
> tabs instead of "<font color=", as the latest was failing to apply
> colors inside anchors and using the A style instead. try grey skin
> in a
> jetspeed-tab to see it.
>
Thanks for that.
Chris
=====
Need somewhere to Live in London - http://freeflats.com
__________________________________________________
Do You Yahoo!?
Get email alerts & NEW webcam video instant messaging with Yahoo! Messenger
http://im.yahoo.com
---------------------------------------------------------------------
To unsubscribe, e-mail: jetspeed-dev-unsubscribe@jakarta.apache.org
For additional commands, e-mail: jetspeed-dev-help@jakarta.apache.org
Re: [PATCH] added some css classes to jetspeed.vm and jetspeed-tab.vm
Posted by Santiago Gala <sg...@hisitech.com>.
Chris Kimpton wrote:
>Hi,
>
>--- Raphaël Luta <ra...@networks.groupvu.com> wrote:
>
>>Chris Kimpton wrote:
>>
>>>The "skin" tool is not in the context for the page as a whole -
>>>
>>where
>>
>>>should this be added?
>>>
>>
>>"skin" is a property of PSML objects so it's not available outside
>>of
>>a the PSML context.
>>Turbine has introduced its own "UIManager" tool for something very
>>similar.
>>It may be possible to merge the two together but I haven't given it
>>much
>>thought yet.
>>
>>
>
>In which case, I'll remove the stylesheet changes and attached is a
>patch for the control based stylesheet skin options only.
>
>The patch uses the stylesheet settings for the default/orange-gray
>skin - but uses no stylesheet classes for the other skins. Thus if
>you login as turbine, you will see a difference.
>
Applied. I changed jetspeed-tab.vm so that it uses style="color: ..." in
tabs instead of "<font color=", as the latest was failing to apply
colors inside anchors and using the A style instead. try grey skin in a
jetspeed-tab to see it.
>
>Regards,
>Chris
>
>
>=====
>Need somewhere to Live in London - http://freeflats.com
>
>__________________________________________________
>Do You Yahoo!?
>Get email alerts & NEW webcam video instant messaging with Yahoo! Messenger
>http://im.yahoo.com
>
>
>------------------------------------------------------------------------
>
>Index: src/java/org/apache/jetspeed/portal/BasePortletSkin.java
>===================================================================
>RCS file: /home/cvspublic/jakarta-jetspeed/src/java/org/apache/jetspeed/portal/BasePortletSkin.java,v
>retrieving revision 1.1
>diff -u -r1.1 BasePortletSkin.java
>--- src/java/org/apache/jetspeed/portal/BasePortletSkin.java 2001/05/27 15:34:35 1.1
>+++ src/java/org/apache/jetspeed/portal/BasePortletSkin.java 2001/09/05 10:42:40
>@@ -210,4 +210,130 @@
> }
> }
>
>+ /**
>+ * Returns the CSS class to use for the portlet overall
>+ * @return the CSS class to use (PortletStyleClass)
>+ */
>+ public String getPortletStyleClass()
>+ {
>+ return (String)get(PORTLET_STYLE_CLASS);
>+ }
>+
>+ /**
>+ * Sets the CSS class to use for the portlet overall
>+ * @param portletStyleClass the new class to be used
>+ */
>+ public void setPortletStyleClass(String portletStyleClass)
>+ {
>+ if (portletStyleClass!=null)
>+ {
>+ put(PORTLET_STYLE_CLASS,portletStyleClass);
>+ }
>+ }
>+
>+ /**
>+ * Returns the CSS class to use for the portlet title
>+ * @return the CSS class to use (TitleStyleClass)
>+ */
>+ public String getTitleStyleClass()
>+ {
>+ return (String)get(TITLE_STYLE_CLASS);
>+ }
>+
>+ /**
>+ * Sets the CSS class to use for the portlet title
>+ * @param titleStyleClass the new class to be used
>+ */
>+ public void setTitleStyleClass(String titleStyleClass)
>+ {
>+ if (titleStyleClass!=null)
>+ {
>+ put(TITLE_STYLE_CLASS,titleStyleClass);
>+ }
>+ }
>+
>+ /**
>+ * Returns the CSS class to use for the portlet content
>+ * @return the CSS class to use (ContentStyleClass)
>+ */
>+ public String getContentStyleClass()
>+ {
>+ return (String)get(CONTENT_STYLE_CLASS);
>+ }
>+
>+ /**
>+ * Sets the CSS class to use for the portlet content
>+ * @param contentStyleClass the new class to be used
>+ */
>+ public void setContentStyleClass(String contentStyleClass)
>+ {
>+ if (contentStyleClass!=null)
>+ {
>+ put(CONTENT_STYLE_CLASS,contentStyleClass);
>+ }
>+ }
>+
>+ /**
>+ * Returns the CSS class to use overall for the tabbed control
>+ * @return the CSS class to use (TabStyleClass)
>+ */
>+ public String getTabStyleClass()
>+ {
>+ return (String)get(TAB_STYLE_CLASS);
>+ }
>+
>+ /**
>+ * Sets the CSS class to use for overall for the tabbed control
>+ * @param tabStyleClass the new class to be used
>+ */
>+ public void setTabStyleClass(String tabStyleClass)
>+ {
>+ if (tabStyleClass!=null)
>+ {
>+ put(TAB_STYLE_CLASS,tabStyleClass);
>+ }
>+ }
>+
>+ /**
>+ * Returns the CSS class to use on the title of the tabbed control
>+ * @return the CSS class to use (TabTitleStyleClass)
>+ */
>+ public String getTabTitleStyleClass()
>+ {
>+ return (String)get(TAB_TITLE_STYLE_CLASS);
>+ }
>+
>+ /**
>+ * Sets the CSS class to use on the title of the tabbed control
>+ * @param tabTitleStyleClass the new class to be used
>+ */
>+ public void setTabTitleStyleClass(String tabTitleStyleClass)
>+ {
>+ if (tabTitleStyleClass!=null)
>+ {
>+ put(TAB_TITLE_STYLE_CLASS,tabTitleStyleClass);
>+ }
>+ }
>+
>+ /**
>+ * Returns the CSS class to use on the control of the tabbed control
>+ * @return the CSS class to use (TabContentStyleClass)
>+ */
>+ public String getTabContentStyleClass()
>+ {
>+ return (String)get(TAB_CONTENT_STYLE_CLASS);
>+ }
>+
>+ /**
>+ * Sets the CSS class to use on the control of the tabbed control
>+ * @param tabContentStyleClass the new class to be used
>+ */
>+ public void setTabContentStyleClass(String tabContentStyleClass)
>+ {
>+ if (tabContentStyleClass!=null)
>+ {
>+ put(TAB_CONTENT_STYLE_CLASS,tabContentStyleClass);
>+ }
>+ }
>+
> }
>Index: src/java/org/apache/jetspeed/portal/PortletSkin.java
>===================================================================
>RCS file: /home/cvspublic/jakarta-jetspeed/src/java/org/apache/jetspeed/portal/PortletSkin.java,v
>retrieving revision 1.1
>diff -u -r1.1 PortletSkin.java
>--- src/java/org/apache/jetspeed/portal/PortletSkin.java 2001/05/27 15:34:35 1.1
>+++ src/java/org/apache/jetspeed/portal/PortletSkin.java 2001/09/05 10:42:40
>@@ -69,6 +69,13 @@
> public static final String TITLE_BACKGROUND_COLOR = "title-background-color";
> public static final String HIGHLIGHT_TEXT_COLOR = "highlight-text-color";
> public static final String HIGHLIGHT_BACKGROUND_COLOR = "highlight-background-color";
>+ public static final String PORTLET_STYLE_CLASS = "portlet-style-class";
>+ public static final String TITLE_STYLE_CLASS = "title-style-class";
>+ public static final String CONTENT_STYLE_CLASS = "content-style-class";
>+ public static final String TAB_STYLE_CLASS = "tab-style-class";
>+ public static final String TAB_TITLE_STYLE_CLASS = "tab-title-style-class";
>+ public static final String TAB_CONTENT_STYLE_CLASS = "tab-content-style-class";
>+ public static final String STYLESHEET = "stylesheet";
>
> /**
> * Returns the name of this color scheme
>@@ -147,5 +154,77 @@
> * @param titleColor the title color value in HTML format (#RRGGBB)
> */
> public void setHighlightBackgroundColor(String titleColor);
>+
>+ /**
>+ * Returns the CSS class to use for the portlet overall
>+ * @return the CSS class to use (PortletStyleClass)
>+ */
>+ public String getPortletStyleClass();
>+
>+ /**
>+ * Sets the CSS class to use for the portlet overall
>+ * @param portletStyleClass the new class to be used
>+ */
>+ public void setPortletStyleClass(String portletStyleClass);
>+
>+ /**
>+ * Returns the CSS class to use for the portlet title
>+ * @return the CSS class to use (TitleStyleClass)
>+ */
>+ public String getTitleStyleClass();
>+
>+ /**
>+ * Sets the CSS class to use for the portlet title
>+ * @param titleStyleClass the new class to be used
>+ */
>+ public void setTitleStyleClass(String titleStyleClass);
>+
>+ /**
>+ * Returns the CSS class to use for the portlet content
>+ * @return the CSS class to use (ContentStyleClass)
>+ */
>+ public String getContentStyleClass();
>+
>+ /**
>+ * Sets the CSS class to use for the portlet content
>+ * @param contentStyleClass the new class to be used
>+ */
>+ public void setContentStyleClass(String contentStyleClass);
>+
>+ /**
>+ * Returns the CSS class to use overall for the tabbed control
>+ * @return the CSS class to use (TabStyleClass)
>+ */
>+ public String getTabStyleClass();
>+
>+ /**
>+ * Sets the CSS class to use for overall for the tabbed control
>+ * @param tabStyleClass the new class to be used
>+ */
>+ public void setTabStyleClass(String tabStyleClass);
>+
>+ /**
>+ * Returns the CSS class to use on the title of the tabbed control
>+ * @return the CSS class to use (TabTitleStyleClass)
>+ */
>+ public String getTabTitleStyleClass();
>+
>+ /**
>+ * Sets the CSS class to use on the title of the tabbed control
>+ * @param tabTitleStyleClass the new class to be used
>+ */
>+ public void setTabTitleStyleClass(String tabTitleStyleClass);
>+
>+ /**
>+ * Returns the CSS class to use on the control of the tabbed control
>+ * @return the CSS class to use (TabContentStyleClass)
>+ */
>+ public String getTabContentStyleClass();
>+
>+ /**
>+ * Sets the CSS class to use on the control of the tabbed control
>+ * @param tabContentStyleClass the new class to be used
>+ */
>+ public void setTabContentStyleClass(String tabContentStyleClass);
>
> }
>Index: webapp/WEB-INF/conf/skins.xreg
>===================================================================
>RCS file: /home/cvspublic/jakarta-jetspeed/webapp/WEB-INF/conf/skins.xreg,v
>retrieving revision 1.3
>diff -u -r1.3 skins.xreg
>--- webapp/WEB-INF/conf/skins.xreg 2001/07/23 21:46:44 1.3
>+++ webapp/WEB-INF/conf/skins.xreg 2001/09/05 10:42:40
>@@ -18,6 +18,12 @@
> <property name="title-background-color" value="#dddddd"/>
> <property name="highlight-text-color" value="#000000"/>
> <property name="highlight-background-color" value="#FFCC00"/>
>+ <property name="portlet-style-class" value="PortletStyleClass"/>
>+ <property name="title-style-class" value="TitleStyleClass"/>
>+ <property name="content-style-class" value="ContentStyleClass"/>
>+ <property name="tab-style-class" value="TabStyleClass"/>
>+ <property name="tab-title-style-class" value="TabTitleStyleClass"/>
>+ <property name="tab-content-style-class" value="TabContentStyleClass"/>
> </skin-entry>
>
> <skin-entry name="orange-red">
>Index: webapp/WEB-INF/templates/vm/controls/html/jetspeed-tab.vm
>===================================================================
>RCS file: /home/cvspublic/jakarta-jetspeed/webapp/WEB-INF/templates/vm/controls/html/jetspeed-tab.vm,v
>retrieving revision 1.3
>diff -u -r1.3 jetspeed-tab.vm
>--- webapp/WEB-INF/templates/vm/controls/html/jetspeed-tab.vm 2001/09/04 11:12:15 1.3
>+++ webapp/WEB-INF/templates/vm/controls/html/jetspeed-tab.vm 2001/09/05 10:42:40
>@@ -2,10 +2,10 @@
> #if ( ! $tabs )
> #parse ("jetspeed.vm")
> #else
>-<table cellpadding="0" cellspacing="0" border="0" width="100%">
>+<table cellpadding="0" cellspacing="0" border="0" width="100%" class="$!{skin.TabStyleClass}">
> <tr>
> <td valign="top">
>- <table align="left" cellspacing="0" border="0" cellpadding="0">
>+ <table align="left" cellspacing="0" border="0" cellpadding="0" class="$!{skin.TabTitleStyleClass}">
> <tr width="100%">
> #foreach ( $tab in $tabs )
> #if ($tab.isSelected() )
>@@ -37,18 +37,21 @@
> </td>
> </tr>
> </table>
>-<table cellspacing="0" width="100%" border="0" cellpadding="0">
>+<table cellspacing="0" width="100%" border="0" cellpadding="0" class="$!{skin.TabStyleClass}">
> <tr><td height="2" bgcolor="$!{skin.HighlightBackgroundColor}"><img height="2" width="2" src="images/dot.gif" /></td></tr>
> <tr><td height="2" bgcolor="$!{skin.BackgroundColor}"><img height="2" width="2" src="images/dot.gif" /></td></tr>
> </table>
>-<table bgcolor="$!{skin.BackgroundColor}" cellspacing="0" width="100%" border="0" cellpadding="0">
>+<table cellspacing="0" width="100%" border="0" cellpadding="0" class="$!{skin.TabStyleClass}"><tr><td>
>+<table bgcolor="$!{skin.BackgroundColor}" cellspacing="0" width="100%"
>+ border="0" cellpadding="0" class="$!{skin.TabContentStyleClass}">
> <tr>
> <td valign="top" width="100%">
> $portlet.getContent($data)
> </td>
> </tr>
> </table>
>+</td></tr></table>
> #end
> #else
> $portlet.getContent($data)
>-#end
>\ No newline at end of file
>+#end
>Index: webapp/WEB-INF/templates/vm/controls/html/jetspeed.vm
>===================================================================
>RCS file: /home/cvspublic/jakarta-jetspeed/webapp/WEB-INF/templates/vm/controls/html/jetspeed.vm,v
>retrieving revision 1.3
>diff -u -r1.3 jetspeed.vm
>--- webapp/WEB-INF/templates/vm/controls/html/jetspeed.vm 2001/09/04 11:12:15 1.3
>+++ webapp/WEB-INF/templates/vm/controls/html/jetspeed.vm 2001/09/05 10:42:40
>@@ -1,21 +1,22 @@
> #if( ! $portlet.isClosed($data) )
>-<table border="0" bgcolor="$!{skin.BackgroundColor}" cellpadding="0" cellspacing="0" width="100%">
>-<tr bgcolor="$!{skin.TitleBackgroundColor}">
>- <td align="left" bgcolor="$!{skin.TitleBackgroundColor}" nowrap="true" valign="middle" width="100%">
>+<table border="0" bgcolor="$!{skin.BackgroundColor}" cellpadding="0" cellspacing="0" width="100%"
>+ class="$!{skin.PortletStyleClass}">
>+<tr bgcolor="$!{skin.TitleBackgroundColor}" class="$!{skin.TitleStyleClass}">
>+ <td align="left" bgcolor="$!{skin.TitleBackgroundColor}"
>+ nowrap="true" valign="middle" width="100%">
> <b><font color="$!{skin.TitleTextColor}">$portlet.Title</font><b>
> </td>
> <td align="right" bgcolor="$!{skin.TitleBackgroundColor}" nowrap="true" valign="middle">
> #foreach ( $action in $actions )
> <a href="${action.Link}" title="${action.Name}"><img src="images/${action.Name}.gif" border="0"></a>
>-
>-
> #end
> </td>
> </tr>
> #if( ! $portlet.isMinimized($data) )
> <tr>
> <td colspan="2" align="center" valign="top" width="100%" >
>- <table border="0" cellpadding="2" cellspacing="0" width="100%" align="center">
>+ <table border="0" cellpadding="2" cellspacing="0"
>+ width="100%" align="center" class="$!{skin.ContentStyleClass}">
> <tr>
> <td>
> $!portlet.getContent($data)
>@@ -26,4 +27,4 @@
> </tr>
> #end
> </table>
>-#end
>\ No newline at end of file
>+#end
>Index: webapp/css/default.css
>===================================================================
>RCS file: /home/cvspublic/jakarta-jetspeed/webapp/css/default.css,v
>retrieving revision 1.2
>diff -u -r1.2 default.css
>--- webapp/css/default.css 2001/07/29 13:42:52 1.2
>+++ webapp/css/default.css 2001/09/05 10:42:41
>@@ -30,3 +30,37 @@
> .MESSAGENEW:link {font-family: "Verdana"; font-size: 8pt; color: NAVY;font-weight: bold}
> .MESSAGENEW:visited {font-family: "Verdana"; font-size: 8pt; color: BLACK;font-weight: bold}
>
>+ .PortletStyleClass
>+ {
>+ padding: 1;
>+ background-color: #AAAAAA;
>+ border: thin gray solid;
>+ }
>+
>+ .TabStyleClass
>+ {
>+ padding: 1;
>+ }
>+
>+ .TitleStyleClass
>+ {
>+ text-transform: uppercase;
>+ font-weight: bold;
>+ }
>+
>+ .TabTitleStyleClass
>+ {
>+ background-color: #FFFFFF;
>+ }
>+
>+ .ContentStyleClass
>+ {
>+ background-color: #FFFFFF;
>+ border-top: thin gray solid;
>+ }
>+
>+ .TabContentStyleClass
>+ {
>+ background-color: #FFFFFF;
>+ }
>+
>
>
>------------------------------------------------------------------------
>
>---------------------------------------------------------------------
>To unsubscribe, e-mail: jetspeed-dev-unsubscribe@jakarta.apache.org
>For additional commands, e-mail: jetspeed-dev-help@jakarta.apache.org
>
> Part 1.1
>
> Content-Type:
>
> text/plain
>
>
> ------------------------------------------------------------------------
> jetspeed2.diffu.txt
>
> Content-Description:
>
> jetspeed2.diffu.txt
> Content-Type:
>
> text/plain
>
>
> ------------------------------------------------------------------------
> Part 1.3
>
> Content-Type:
>
> text/plain
>
>
---------------------------------------------------------------------
To unsubscribe, e-mail: jetspeed-dev-unsubscribe@jakarta.apache.org
For additional commands, e-mail: jetspeed-dev-help@jakarta.apache.org
Re: [PATCH] added some css classes to jetspeed.vm and jetspeed-tab.vm
Posted by Chris Kimpton <ki...@yahoo.com>.
Hi,
--- Rapha�l Luta <ra...@networks.groupvu.com> wrote:
> Chris Kimpton wrote:
>
> > The "skin" tool is not in the context for the page as a whole -
> where
> > should this be added?
> >
>
>
> "skin" is a property of PSML objects so it's not available outside
> of
> a the PSML context.
> Turbine has introduced its own "UIManager" tool for something very
> similar.
> It may be possible to merge the two together but I haven't given it
> much
> thought yet.
>
>
In which case, I'll remove the stylesheet changes and attached is a
patch for the control based stylesheet skin options only.
The patch uses the stylesheet settings for the default/orange-gray
skin - but uses no stylesheet classes for the other skins. Thus if
you login as turbine, you will see a difference.
Regards,
Chris
=====
Need somewhere to Live in London - http://freeflats.com
__________________________________________________
Do You Yahoo!?
Get email alerts & NEW webcam video instant messaging with Yahoo! Messenger
http://im.yahoo.com
Re: [PATCH] added some css classes to jetspeed.vm and jetspeed-tab.vm
Posted by Raphaël Luta <ra...@networks.groupvu.com>.
Chris Kimpton wrote:
> Hi,
>
>
> The "skin" tool is not in the context for the page as a whole - where
> should this be added?
>
"skin" is a property of PSML objects so it's not available outside of
a the PSML context.
Turbine has introduced its own "UIManager" tool for something very similar.
It may be possible to merge the two together but I haven't given it much
thought yet.
> How do you use skin properties in the jsp pages?
>
Either you use the Java API directly in the JSP:
PortletSkin skin = portlet.getPortletConfig().getPortletSkin()
or (better) you write a JetspeedSkin dynamic tag to wrap the skin
functionality and add it to the Jetspeed TLD.
--
Raphael Luta - raphael.luta@networks.groupvu.com
Vivendi Universal Networks - Paris
---------------------------------------------------------------------
To unsubscribe, e-mail: jetspeed-dev-unsubscribe@jakarta.apache.org
For additional commands, e-mail: jetspeed-dev-help@jakarta.apache.org
Re: [PATCH] added some css classes to jetspeed.vm and jetspeed-tab.vm
Posted by Chris Kimpton <ki...@yahoo.com>.
Hi,
>
> o The vm must only set the CSS when a CSS exists. This will allow
> portlet
> to inherit the CSS of their parent.
Not sure what you mean here, if the CSS class is not specified, a
class="" will be returned, which means all other stylings will be
used.
>
> o Which elements, i.e. Portlet Box, Portlet Titles, Portlet
> Content...
> will have a configurable CSS.
>
I have only the following 6 currently
Portlet as a whole
Portlet title
Portlet content
Tabbed pane as a whole
Tabbed pane title
Tabbed pane content
Attached is a revised patch.
...but I have some problems with using a skin for the overall page
stylesheet.
The "skin" tool is not in the context for the page as a whole - where
should this be added?
How do you use skin properties in the jsp pages?
Regards,
Chris
=====
Need somewhere to Live in London - http://freeflats.com
__________________________________________________
Do You Yahoo!?
Get email alerts & NEW webcam video instant messaging with Yahoo! Messenger
http://im.yahoo.com
Re: [PATCH] added some css classes to jetspeed.vm and jetspeed-tab.vm
Posted by Paul Spencer <pa...@mikon.com>.
Chris,
Chris Kimpton wrote:
>
> Hi,
>
> --- Paul Spencer <pa...@mikon.com> wrote:
> > I would prefer to see the CSS associated to a skin. That way a
> > portal
> > with 3 columns could have a different look, via CSS, in each
> > column. As
> > an example the first column is a navigation with the default font
> > bolded. The second column contains RSS feeds with no special
> > formatting. The third columns contains portlets in orange boxes.
> >
>
> So that I am clear on what you are saying, rather than specifying the
> class directly in the vm, as in the patch, we should get the class
> from the skin and then the skin would have the default class, but
> could be overridden via psml - or perhaps in other ways too...
>
> So the class lines would be for example:
>
> class="$!{skin.TitleStyleClass}"
>
> If so, thats fine, I'll submit a revised patch.
I believe you have the idea, although I do not believe the
implementation is a simple as patching the .vm.
Some, by no means all, items that should be addressed:
o Support for a CSS class must be added to the skin.
o The vm must only set the CSS when a CSS exists. This will allow
portlet
to inherit the CSS of their parent.
o Which elements, i.e. Portlet Box, Portlet Titles, Portlet Content...
will have a configurable CSS.
>
> Regards,
> Chris
>
Paul Spencer
---------------------------------------------------------------------
To unsubscribe, e-mail: jetspeed-dev-unsubscribe@jakarta.apache.org
For additional commands, e-mail: jetspeed-dev-help@jakarta.apache.org
Re: [PATCH] added some css classes to jetspeed.vm and jetspeed-tab.vm
Posted by Chris Kimpton <ki...@yahoo.com>.
Hi,
--- Paul Spencer <pa...@mikon.com> wrote:
> I would prefer to see the CSS associated to a skin. That way a
> portal
> with 3 columns could have a different look, via CSS, in each
> column. As
> an example the first column is a navigation with the default font
> bolded. The second column contains RSS feeds with no special
> formatting. The third columns contains portlets in orange boxes.
>
So that I am clear on what you are saying, rather than specifying the
class directly in the vm, as in the patch, we should get the class
from the skin and then the skin would have the default class, but
could be overridden via psml - or perhaps in other ways too...
So the class lines would be for example:
class="$!{skin.TitleStyleClass}"
If so, thats fine, I'll submit a revised patch.
Regards,
Chris
=====
Need somewhere to Live in London - http://freeflats.com
__________________________________________________
Do You Yahoo!?
Get email alerts & NEW webcam video instant messaging with Yahoo! Messenger
http://im.yahoo.com
---------------------------------------------------------------------
To unsubscribe, e-mail: jetspeed-dev-unsubscribe@jakarta.apache.org
For additional commands, e-mail: jetspeed-dev-help@jakarta.apache.org
Re: [PATCH] added some css classes to jetspeed.vm and jetspeed-tab.vm
Posted by Paul Spencer <pa...@mikon.com>.
I would prefer to see the CSS associated to a skin. That way a portal
with 3 columns could have a different look, via CSS, in each column. As
an example the first column is a navigation with the default font
bolded. The second column contains RSS feeds with no special
formatting. The third columns contains portlets in orange boxes.
This would give the user the greatest flexibility without having to edit
any .vm or .jsp files.
Paul Spencer
Chris Kimpton wrote:
>
> Hi,
>
> --- Santiago Gala <sg...@hisitech.com> wrote:
> >
> > Other thing that is misserably failing is that the way we apply
> > skins
> > interferes with the CSS applied, so the grey skin shows black text
> > on
> > black background for selected tab (under Mozilla at least). I think
> > we
> > should go either ofr a full CSS definition, thus using styles in
> > the
> > controls and controllers, or for a "conventional" skinning scheme,
> > and
> > stop using the CSS file.
> >
>
> Following on from that theme then,
>
> I made changes all to add class= options. Thus the changes only
> impact jetspeed/-tab.vm. I've taken the liberty of putting some
> samples in the defaults.css too. Feel free to remove/amend/change as
> you see fit.
>
> diff -u's attached.
>
> I've not removed any existing customisation - it will work if the css
> entry is NOT used, eg blank - but the CSS stuff overrides the inline
> settings, eg border=, bgcolor= etc if it set.
>
> Thus it should be fully backwards compatible by removing/blanking out
> the style entries in the default.css.
>
> Regards,
> Chris
>
> =====
> Need somewhere to Live in London - http://freeflats.com
>
> __________________________________________________
> Do You Yahoo!?
> Get email alerts & NEW webcam video instant messaging with Yahoo! Messenger
> http://im.yahoo.com
>
> ------------------------------------------------------------------------
> Index: WEB-INF/templates/vm/controls/html/jetspeed-tab.vm
> ===================================================================
> RCS file: /home/cvspublic/jakarta-jetspeed/webapp/WEB-INF/templates/vm/controls/html/jetspeed-tab.vm,v
> retrieving revision 1.3
> diff -u -r1.3 jetspeed-tab.vm
> --- WEB-INF/templates/vm/controls/html/jetspeed-tab.vm 2001/09/04 11:12:15 1.3
> +++ WEB-INF/templates/vm/controls/html/jetspeed-tab.vm 2001/09/04 16:36:47
> @@ -2,10 +2,10 @@
> #if ( ! $tabs )
> #parse ("jetspeed.vm")
> #else
> -<table cellpadding="0" cellspacing="0" border="0" width="100%">
> +<table cellpadding="0" cellspacing="0" border="0" width="100%" class="TabStyleClass">
> <tr>
> <td valign="top">
> - <table align="left" cellspacing="0" border="0" cellpadding="0">
> + <table align="left" cellspacing="0" border="0" cellpadding="0" class="TabTitleStyleClass">
> <tr width="100%">
> #foreach ( $tab in $tabs )
> #if ($tab.isSelected() )
> @@ -37,18 +37,21 @@
> </td>
> </tr>
> </table>
> -<table cellspacing="0" width="100%" border="0" cellpadding="0">
> +<table cellspacing="0" width="100%" border="0" cellpadding="0" class="TabStyleClass">
> <tr><td height="2" bgcolor="$!{skin.HighlightBackgroundColor}"><img height="2" width="2" src="images/dot.gif" /></td></tr>
> <tr><td height="2" bgcolor="$!{skin.BackgroundColor}"><img height="2" width="2" src="images/dot.gif" /></td></tr>
> </table>
> -<table bgcolor="$!{skin.BackgroundColor}" cellspacing="0" width="100%" border="0" cellpadding="0">
> +<table cellspacing="0" width="100%" border="0" cellpadding="0" class="TabStyleClass"><tr><td>
> +<table bgcolor="$!{skin.BackgroundColor}" cellspacing="0" width="100%"
> + border="0" cellpadding="0" class="TabContentStyleClass">
> <tr>
> <td valign="top" width="100%">
> $portlet.getContent($data)
> </td>
> </tr>
> </table>
> +</td></tr></table>
> #end
> #else
> $portlet.getContent($data)
> -#end
> \ No newline at end of file
> +#end
> Index: WEB-INF/templates/vm/controls/html/jetspeed.vm
> ===================================================================
> RCS file: /home/cvspublic/jakarta-jetspeed/webapp/WEB-INF/templates/vm/controls/html/jetspeed.vm,v
> retrieving revision 1.3
> diff -u -r1.3 jetspeed.vm
> --- WEB-INF/templates/vm/controls/html/jetspeed.vm 2001/09/04 11:12:15 1.3
> +++ WEB-INF/templates/vm/controls/html/jetspeed.vm 2001/09/04 16:36:47
> @@ -1,21 +1,22 @@
> #if( ! $portlet.isClosed($data) )
> -<table border="0" bgcolor="$!{skin.BackgroundColor}" cellpadding="0" cellspacing="0" width="100%">
> -<tr bgcolor="$!{skin.TitleBackgroundColor}">
> - <td align="left" bgcolor="$!{skin.TitleBackgroundColor}" nowrap="true" valign="middle" width="100%">
> +<table border="0" bgcolor="$!{skin.BackgroundColor}" cellpadding="0" cellspacing="0" width="100%"
> + class="PortletStyleClass">
> +<tr bgcolor="$!{skin.TitleBackgroundColor}" class="TitleStyleClass">
> + <td align="left" bgcolor="$!{skin.TitleBackgroundColor}"
> + nowrap="true" valign="middle" width="100%">
> <b><font color="$!{skin.TitleTextColor}">$portlet.Title</font><b>
> </td>
> <td align="right" bgcolor="$!{skin.TitleBackgroundColor}" nowrap="true" valign="middle">
> #foreach ( $action in $actions )
> <a href="${action.Link}" title="${action.Name}"><img src="images/${action.Name}.gif" border="0"></a>
> -
> -
> #end
> </td>
> </tr>
> #if( ! $portlet.isMinimized($data) )
> <tr>
> <td colspan="2" align="center" valign="top" width="100%" >
> - <table border="0" cellpadding="2" cellspacing="0" width="100%" align="center">
> + <table border="0" cellpadding="2" cellspacing="0"
> + width="100%" align="center" class="ContentStyleClass">
> <tr>
> <td>
> $!portlet.getContent($data)
> @@ -26,4 +27,4 @@
> </tr>
> #end
> </table>
> -#end
> \ No newline at end of file
> +#end
> Index: css/default.css
> ===================================================================
> RCS file: /home/cvspublic/jakarta-jetspeed/webapp/css/default.css,v
> retrieving revision 1.2
> diff -u -r1.2 default.css
> --- css/default.css 2001/07/29 13:42:52 1.2
> +++ css/default.css 2001/09/04 16:36:47
> @@ -30,3 +30,37 @@
> .MESSAGENEW:link {font-family: "Verdana"; font-size: 8pt; color: NAVY;font-weight: bold}
> .MESSAGENEW:visited {font-family: "Verdana"; font-size: 8pt; color: BLACK;font-weight: bold}
>
> + .PortletStyleClass
> + {
> + padding: 1;
> + background-color: #AAAAAA;
> + border: thin gray solid;
> + }
> +
> + .TabStyleClass
> + {
> + padding: 1;
> + }
> +
> + .TitleStyleClass
> + {
> + text-transform: uppercase;
> + font-weight: bold;
> + }
> +
> + .TabTitleStyleClass
> + {
> + background-color: #FFFFFF;
> + }
> +
> + .ContentStyleClass
> + {
> + background-color: #FFFFFF;
> + border-top: thin gray solid;
> + }
> +
> + .TabContentStyleClass
> + {
> + background-color: #FFFFFF;
> + }
> +
>
> ------------------------------------------------------------------------
> ---------------------------------------------------------------------
> To unsubscribe, e-mail: jetspeed-dev-unsubscribe@jakarta.apache.org
> For additional commands, e-mail: jetspeed-dev-help@jakarta.apache.org
---------------------------------------------------------------------
To unsubscribe, e-mail: jetspeed-dev-unsubscribe@jakarta.apache.org
For additional commands, e-mail: jetspeed-dev-help@jakarta.apache.org
Re: [PATCH] added some css classes to jetspeed.vm and jetspeed-tab.vm
Posted by Chris Kimpton <ki...@yahoo.com>.
Hi,
--- Frans Thamura <ft...@yahoo.com> wrote:
> Dear All.
>
> this is my comment to CSS in jetspeed.vm.
>
> I agree with that..
>
> but..
>
> I prefer there is a skin/theme for Jetspeed rather to
> put CSS there...
>
> For preferences, look at theme in phpnuke.org or
> nukeaddon.com created by my friend.
>
This sounds like the actual selection of the css file should be done
through the skin stuff too. It allows for the kind of thing they are
doing - but I guess it will need more support in the admin/user
preferences for it to be fully used.
This should be straightforward to do.
Regards,
Chris
PS Yep, I realise its more than a vm change.... here goes nothing....
=====
Need somewhere to Live in London - http://freeflats.com
__________________________________________________
Do You Yahoo!?
Get email alerts & NEW webcam video instant messaging with Yahoo! Messenger
http://im.yahoo.com
---------------------------------------------------------------------
To unsubscribe, e-mail: jetspeed-dev-unsubscribe@jakarta.apache.org
For additional commands, e-mail: jetspeed-dev-help@jakarta.apache.org
Re: [PATCH] added some css classes to jetspeed.vm and jetspeed-tab.vm
Posted by Frans Thamura <ft...@yahoo.com>.
Dear All.
this is my comment to CSS in jetspeed.vm.
I agree with that..
but..
I prefer there is a skin/theme for Jetspeed rather to
put CSS there...
For preferences, look at theme in phpnuke.org or
nukeaddon.com created by my friend.
Frans
=====
Let's Empowering Open Source Spirit...
Open Source is Open Source. Shared Source is another thing.
__________________________________________________
Do You Yahoo!?
Get email alerts & NEW webcam video instant messaging with Yahoo! Messenger
http://im.yahoo.com
---------------------------------------------------------------------
To unsubscribe, e-mail: jetspeed-dev-unsubscribe@jakarta.apache.org
For additional commands, e-mail: jetspeed-dev-help@jakarta.apache.org
[PATCH] added some css classes to jetspeed.vm and jetspeed-tab.vm
Posted by Chris Kimpton <ki...@yahoo.com>.
Hi,
--- Santiago Gala <sg...@hisitech.com> wrote:
>
> Other thing that is misserably failing is that the way we apply
> skins
> interferes with the CSS applied, so the grey skin shows black text
> on
> black background for selected tab (under Mozilla at least). I think
> we
> should go either ofr a full CSS definition, thus using styles in
> the
> controls and controllers, or for a "conventional" skinning scheme,
> and
> stop using the CSS file.
>
Following on from that theme then,
I made changes all to add class= options. Thus the changes only
impact jetspeed/-tab.vm. I've taken the liberty of putting some
samples in the defaults.css too. Feel free to remove/amend/change as
you see fit.
diff -u's attached.
I've not removed any existing customisation - it will work if the css
entry is NOT used, eg blank - but the CSS stuff overrides the inline
settings, eg border=, bgcolor= etc if it set.
Thus it should be fully backwards compatible by removing/blanking out
the style entries in the default.css.
Regards,
Chris
=====
Need somewhere to Live in London - http://freeflats.com
__________________________________________________
Do You Yahoo!?
Get email alerts & NEW webcam video instant messaging with Yahoo! Messenger
http://im.yahoo.com
Re: Additions to the skin class - anyone changing this?
Posted by Santiago Gala <sg...@hisitech.com>.
Chris Kimpton wrote:
>Hi,
>
>I want to add 2 more properties for skins
>
>. TitleStyleClass
> - to be used against the class attribute on the title of a portlet.
>
>Lets you use those funky CSS formatting options
>
>. ContentBackgroundColor
> - to be used as the bgcolor for the innermost table containing the
>content. This lets you do those thin line bordered portlets, by
>giving the overall portlet a dark bgcolor and then setting this
>bgcolor to be a lighter colour.
>
>Is this ok? Anyone else doing anything similar? Any other requests?
>
>I've just started looking at it, but it looks like I need to change
>
>PortletSkin.java
>BasePortletSkin.java
>skins.xreg
>jetspeed.vm
>
>I'll send some patches later.
>
Try to send your patches as attachments, since the word wrapping of the
mailer spoils them.
I had to reconstruct your former patch by hand.
Thanks for your work.
Other thing that is misserably failing is that the way we apply skins
interferes with the CSS applied, so the grey skin shows black text on
black background for selected tab (under Mozilla at least). I think we
should go either ofr a full CSS definition, thus using styles in the
controls and controllers, or for a "conventional" skinning scheme, and
stop using the CSS file.
Oppinions on this one?
>
>Regards,
>Chris
>
>=====
>Need somewhere to Live in London - http://freeflats.com
>
>__________________________________________________
>Do You Yahoo!?
>Get email alerts & NEW webcam video instant messaging with Yahoo! Messenger
>http://im.yahoo.com
>
>---------------------------------------------------------------------
>To unsubscribe, e-mail: jetspeed-dev-unsubscribe@jakarta.apache.org
>For additional commands, e-mail: jetspeed-dev-help@jakarta.apache.org
>
---------------------------------------------------------------------
To unsubscribe, e-mail: jetspeed-dev-unsubscribe@jakarta.apache.org
For additional commands, e-mail: jetspeed-dev-help@jakarta.apache.org