Customizing Themes and Adding Zimbra Powered Logo - Open Source Edition

From Zimbra :: Wiki

Jump to: navigation, search
Developer Article

Article Information

This article applies to the following ZCS versions.
  ZCS 4.5 Article  ZCS 4.5

Topic describes changes for 4.5.x Themes, for information about ZCS 5.0 Themes, see the ZWC 5.0 Themes

The appearance of the Zimbra Web Client user interface can be customized. Changing the appearance of the interface can be as easy as selecting which Zimbra themes are available to the users or you can customize one of the themes provided.

If you are using the Zimbra Collaboration Suite Open Source edition license, and have modified the software, you are required to use the Zimbra Inside logo on the web client interface. This document explains how to

  •   Modify a Class of Service to limit the choice of themes available.
  • Create customized themes from the sample themes provided and add the Zimbra Inside logo.
  • Add the Zimbra Inside logo to display in a specific Zimbra theme .
  • Add the Zimbra Inside logo to display in all Zimbra themes.

If you have questions about themes or have designed themes you want to share, post them to the Zimbra Forums.

Contents

License Policy

If the Zimbra Collaboration Suite open source editon software code is modified, the “Zimbra Powered" logo must be placed in the Zimbra Web Client user interface. If a Zimbra theme is modified or Zimlets are added to ZCS, the original Zimbra logo must be displayed.

Under fair use practice, you can describe your service as being based on Zimbra, such as "Acme hosted email using the Zimbra Collaboration Suite," but you generally cannot use the Zimbra name within your own branding such as "Acme Zimbra hosted email." Moreover, unless you are an accredited partner within the Zimbra Partner Program, you are not permitted to use any of the Zimbra logos other than their appropriate occurrence within the Zimbra software itself.

If you are producing a derivative work (that is, making changes to the source code) of ZCS, Open Source Edition, you are bound by the terms of the Zimbra open source licenses (see the Zimbra Collective License and the Zimbra Public License). Under the Zimbra Public License (ZPL), all derivative works of the ZCS Ajax/Javascript client must carry the "Zimbra Powered" logo in place of the original Zimbra logo. When users click on the “Zimbra Powered" logo, it must direct them to the Zimbra website.

Additional information about the license usage can be found at http://www.zimbra.com/license/index.html.

See http://www.zimbra.com/partners/trademark_branding_faq.html for more FAQs about proper use of Zimbra logo. See the media page to download the logo images.

Customizing ZWC Using Class of Service

ZCS offers a selection of themes for the Zimbra Web Client (ZWC). The theme that displays as the default on the ZWC and the themes that users can select in the ZWC Options General tab can be configured in Classes of Service from the administration console. The following theme usage options can be configured:

  • Limit users to one theme. On the COS Themes tab, select the theme to use from the Current UI theme drop-down list. On the Features tab, remove the checkmark from Change UI themes.
  • Let users access any of the installed Zimbra themes. On the COS Themes tab, check Do not limit Themes available to users in this COS. Users can access any of the themes that are listed in the Themes tab. Note: Change UI themes must be checked on the COS Features tab.
  • Select specific themes that users can use. On the COS Themes tab, select Limit Themes available to users in this COS to: and then check the themes users can use. Note: Change UI themes must be checked on the COS Features tab.

Creating Customized Theme from Sample Themes

To customize the ZWC user interface’s color scheme, you can modify one of the sample themes. Two sample themes are provided with generic color variants of either light or white. You can customize the theme colors using the Theme Color Picker which lets you quickly set the colors and their variants.

  • Light – The color scheme is light, with black text. An example of this is the Zimbra Sand theme.

Image004.jpg

  • White – The color scheme is white, with black text. An example of this is the Zimbra Vanilla theme.

Image005.jpg

You can view these examples from the Zimbra Web Client, go to the Options, General tab, UI Theme and select to view the theme.

Changing Zimbra Sample Themes

When you install Zimbra Collaboration Suite, theme files are installed in the /opt/zimbra/tomcat/webapps/zimbra/skins directory. You will add your customized theme directory to the /skins directory. NOTE: for version 5.x replace 'tomcat' with 'jetty'.

Each theme directory has one .xml file and one .txt file. The .xml file is the manifest file, which is a central list of all other files that make up the theme. The subs.txt file is where colors are defined and the Zimbra Powered logo configured.

Note: You can modify any of the themes. If you customize a Zimbra theme that is in the /skins directory, we recommend that you copy and rename the theme, following the same directions as for changing sample themes. Change any occurrence of the Zimbra theme name to the your theme name.

How to change a sample theme

1.     Go to the following Zimbra directory, /opt/zimbra/tomcat/webapps/zimbra/skins/_sample

The _sample directory includes the sample folders, light and white.

2.     Copy the sample theme directory you have chosen from the /_samples directory to the /skins directory. When you copy it, change the sample theme name to your theme name.

cp –r <sampletheme> /opt/zimbra/tomcat/webapps/zimbra/skins/<mytheme>

3.     Change the name of the files in the <mytheme> directory to your theme name. Make sure you do not change the extensions.

mv <sampletheme.xml> <mytheme>.xml

mv <sampletheme_subs.text <mytheme>_subs.txt

Your theme directory should look like this:

/skin/mytheme/

mytheme.xml

mytheme_subs.txt

 

4.     Edit mytheme.xml. Look for <file>[skin]_subs.txt</file> and change the occurrence of "[skin]" to your theme name.

$ vi mytheme.xml

<skin>

<substitutions>

<file>../_base/base/base_subs.txt</file>

<file>../_base/light/light_subs.txt</file>

<file>mytheme_subs.txt</file>

</substitutions>

<css>

<file>../_base/base/base.css</file>

</css>

<html>

<file>../_base/base/base.html</file>

</html>

</skin>

5.     Edit <mytheme>_subs.txt

a.     Where you see SkinName = [skin], change "[skin]" to your theme file name, for example, SkinName = mytheme.

b.     If you modified the Zimbra software, you must configure the Zimbra Powered logo. In the section that says “If you are using ZCS under the open source license, and you have modified the software, then you are required to use the Zimbra Inside logo. To display the logo, uncomment the lines that starts with LogoImgDir and LogoURL.

c.      Optionally, you can customize the skin colors that display.

The themes _subs.txt file defines a single _BaseColor_ and variances that is used to give the theme a consistent color theme. If you want to modify the colors of the theme, use the Theme Color Picker to pick the colors interactively and then copy and paste the list of color variants over the list in your mytheme_subs.txt file. See Using the Theme Color Picker section.

#############################################################

# Skin Substitutions

#------------------------------------------------------------#

#

# Add or change entries below to customize this skin.

# See: http://wiki.zimbra.com/?title=Themes

#

# NOTE: Substitutions that begin and end with "_" (eg:
# "_BaseColor_")should only be used within this file -- never in # a CSS or HTML file

#

# ===========================================================#

 

SkinName = mytheme

 

###############################################################

# Logo Licensing Rules #

#-----------------------------------------------------------#

#

# If you are using the Zimbra Collaboration Suite (ZCS) under the

# open source license, and you have not modified the software,

# then you are required to use the Zimbra logo (the default).

#

# LogoImgDir = /zimbra/skins/_base/logos

# LogoURL = http: //www.zimbra.com

#

#-----------------------------------------------------------

# If you are using ZCS under the open source license,

# and you have modified the software,

# then you are required to use the Zimbra Inside logo.

#

# LogoImgDir = /zimbra/skins/_base/logos/ZimbraInside

# LogoURL = http:// www.zimbra.com

#

#------------------------------------------------------------

#

#============================================================#

 

# Skin Colors #

#-------------------------------------------------------------#

#### Base color and variants ####

_BaseColor_ = #ff7373

_BaseColorD95_ = #0d0606

_BaseColorD90_ = #1a0c0c

.

6.     Now modify the Zimbra configuration to add your customized theme and stop and start the server.

To modify the configuration, type

zmprov mcf +zimbraInstalledSkin <mytheme>

7.     Stop the server, type

zmcontrol stop

8.     When the services are stopped, restart the server, type

zmcontrol start

The customized theme is now listed in the administration console’s COS and Accounts UI Theme list.

If you want users to access only this theme, modify Classes of Service to make this theme the Current UI theme and disable the Change UI themes feature.

IMPORTANT: If users have been using Zimbra Collaboration Suite, they may need to clear their browser’s cache before the new logos are displayed.

Using the Theme Color Picker

To change the colors of a theme use the ZCS Theme Color Picker to create different color variants. As you select different colors, the Theme Color Picker automatically updates the color variants RGB value in the Theme Color Picker list. This list is then copied and pasted to the subs.txt file.

A theme defines a single _BaseColor_ that is used to give the UI a consistent color theme. The HTML, CSS, and substitution files are crafted to use subtle light and dark variants of this color to achieve effects like buttons that look like they rise and lower, without the use of images. To change a _BaseColor_, use the ZCS Theme Color Picker to pick the color interactively. Copy and paste the list of color variants into the _BaseColor_ [theme]_subs.txt file.

Themes also define a _SelColor_ which is the color used to show selected rows in lists, default buttons, etc. To define a _SelColor_, use the Theme Color Picker to pick the color interactively. Copy and past the list of color variants into the _SelColor_section of the [theme]_subs.txt file.

The ZCS Theme Color Picker file is installed on the following directory on the Zimbra server /opt/zimbra/tomcat/webapps/zimbra/skins/_sample. To open this file from your browser, type http://YOUR SERVER/zimbra/skins/_sample/ZCSThemeColorPicker.html.

Adding Zimbra Powered Logo to a Zimbra theme

You can add Zimbra Powered to any of the Zimbra themes in the skins directory.

1.     Go to the following Zimbra directory, /opt/zimbra/tomcat/webapps/zimbra/skins/

The skins directory includes all the available Zimbra themes.

2.     Select a theme and go to that theme’s directory.

3.     Edit the theme’s _subs.txt.

In the section that says “If you are using ZCS under the open source license, and you have modified the software, then you are required to use the Zimbra Inside logo, uncomment the lines that starts with LogoImgDir and LogoURL.

#-------------------------------------------------------

# If you are using ZCS under the open source license,

# and you have modified the software,

# then you are required to use the Zimbra Inside logo.

#

# LogoImgDir = /zimbra/skins/_base/logos/ZimbraInside

# LogoURL = http:// www.zimbra.com

#-------------------------------------------------------

 

# If you are using ZCS under the network (commercial) license,

# then you are welcome to use your own logo in place of the

4.     Save your changes. Now you will need to deploy your changes.

5.     Stop the server, type

zmcontrol stop

6.     Start the server, type

zmcontrol start

Adding Zimbra Powered Logo to All Zimbra Themes

To display Zimbra Powered in all Zimbra themes, you modify the base_subs.txt file.

1.     Go to /opt/zimbra/tomcat/webapps/zimbra/skins/_base/base

2.     Edit the base_subs.txt file. In the file where it reads “If you are using ZCS under the open source license, and you have modified the software, then you are required to use the Zimbra Inside logo.”:

a.     Uncomment the line that starts with LogoImgDir

b.     Uncomment the line with LogoURL.

#========================================================================#

 

 

SkinName = base

 

 

##########################################################################

# Logo Licensing Rules #

#------------------------------------------------------------------------#

#

# If you are using the Zimbra Collaboration Suite (ZCS) under the open
# source license, and you have not modifed the software,

# then you are required to use the Zimbra logo (the default).

#

# LogoImgDir = /zimbra/skins/_base/logos

# LogoURL = http:// www.zimbra.com

#-------------------------------------------------------------------------

# If you are using ZCS under the open source license,

# and you have modified the software,

# then you are required to use the Zimbra Inside logo.

#

LogoImgDir = /zimbra/skins/_base/logos/ZimbraInside

LogoURL = http:/ /www.zimbra.com

#

#-------------------------------------------------------------------------

 

3.     Save your changes.

4.     Stop and start the Zimbra server to display the Zimbra Inside logo.

a.     Stop the server, type

zmcontrol stop

b.     When the services are stopped, restart the server, type

zmcontrol start

 

Personal tools