Requirement Constraints

  • Subscribe to our RSS feed.
  • Twitter
  • StumbleUpon
  • Reddit
  • Facebook
  • Digg

Saturday, 20 October 2012

ZK Button CSS Customization

Posted on 22:48 by Unknown
image

<?page title="All Buttons" contentType="text/html;charset=UTF-8"?>
<zk>
    <style>
        .GridLayoutNoBorder tr.z-row td.z-row-inner, tr.z-row
        .z-cell,div.z-grid {
            border: none;
            overflow: hidden;
            zoom: 1;
            background: white;
            border-top: none;
            border-left: none;
            border-right: none;
            border-bottom: none;
        }
          .btndiv .z-button-cr, .btndiv .z-button-cl,
        .btndiv .z-button-bl, .btndiv .z-button-bm,
        .btndiv .z-button-br, .btndiv .z-button-tl,
        .btndiv .z-button-tm, .btndiv .z-button-tr {
            background-image: none;
        }
       
        .btndiv .z-button-cm {
            background : transparent url('') no-repeat 0 0 ;
        }
        .btndiv table {
            width: 100%;
            height: 100%;
        }
        .myGreen {
            width: 110px;
            height: 39px;
            height: 37px\9;
        }

        .myGreen .z-button-cm {
            height: 31px;
            color: black;
        }
       
        .myGreen .z-button-cm { background-image:url('http://www.zkoss.org/zkdemo/widgets/styling/custom_style/img/button3.png');
        }
       
        .z-button-focus .z-button-cm {
            background-position: 0 -62px                   
        }
       
        .z-button-over .z-button-cm {
            background-position: 0 -31px
        }
       
        .z-button-clk .z-button-cm {
            background-position: 0 -93px                   
        }              
       

        .cw-notes-header-btn {
            color: white;
            font-family: Helvetica,    Arial, Sans-Serif; font-size: 16px;
            text-decoration: none;
            text-shadow: -1px -1px 1px #616161;
            position: relative;

            -webkit-box-shadow: 3px 3px 0 #9a9a9a;
            -moz-box-shadow: 3px 3px 0 #9a9a9a;
            -webkit-transition: all 0.3s ease;
            -moz-transition: all 0.3s ease;
            padding: 5px;
            background:#1F4D69;
        }

        .cw-notes-header-btn:hover {
            -webkit-box-shadow: 0px 0px 0 #1F4D69;
            -moz-box-shadow: 0px 0px 0 #1F4D69;
            top: 1px;
            left:1px;
            background:#656565;
        }

        .rounded_corner {
            color: white;
            font-family: Helvetica,    Arial, Sans-Serif; font-size: 16px;
            text-decoration: none;
            text-shadow: -1px -1px 1px #616161;
            position: relative;
           
            -webkit-border-radius: .5em;
            -moz-border-radius: .5em;
            border-radius: .5em;   
            -webkit-box-shadow: 3px 3px 0 #9a9a9a;
            -moz-box-shadow: 3px 3px 0 #9a9a9a;
            -webkit-transition: all 0.3s ease;
            -moz-transition: all 0.3s ease;
            padding: 5px;
            background:#1F4D69;
        }

        .rounded_corner:hover {
            -webkit-box-shadow: 0px 0px 0 #1F4D69;
            -moz-box-shadow: 0px 0px 0 #1F4D69;
            top: 1px; left:1px;
            background:#656565;
        }
       
.mybutton.z-button .z-button-cm {
    background-image: none;
}

.mybutton.z-button .z-button-tm, .mybutton.z-button .z-button-bm {
    background-image: none;
}

.mybutton.z-button .z-button-cl, .mybutton.z-button .z-button-cr {
    background-image: none;
}

.mybutton.z-button .z-button-tl {
   background-image: none;
}

.mybutton.z-button .z-button-bl {
   background-image: none;
}

.mybutton.z-button .z-button-tr {
   background-image: none;
}

.mybutton.z-button .z-button-br {
   background-image: none;
}

.button {
    display: inline-block;
    zoom: 1; /* zoom and *display = ie7 hack for display:inline-block */
    *display: inline;
    vertical-align: baseline;
    margin: 0 2px;
    outline: none;
    cursor: pointer;
    text-align: center;
    text-decoration: none;
    font: 14px/100% Arial, Helvetica, sans-serif;
    padding: .5em 2em .55em;
    text-shadow: 0 1px 1px rgba(0,0,0,.3);
    -webkit-border-radius: .5em;
    -moz-border-radius: .5em;
    border-radius: .5em;
    -webkit-box-shadow: 0 1px 2px rgba(0,0,0,.2);
    -moz-box-shadow: 0 1px 2px rgba(0,0,0,.2);
    box-shadow: 0 1px 2px rgba(0,0,0,.2);
}
.button:hover {
    text-decoration: none;
}
.button:active {
    position: relative;
    top: 1px;
}

.bigrounded {
    -webkit-border-radius: 2em;
    -moz-border-radius: 2em;
    border-radius: 2em;
}
.medium {
    font-size: 12px;
    padding: .4em 1.5em .42em;
}
.small {
    font-size: 11px;
    padding: .2em 1em .275em;
}

.green {
    color: #e8f0de;
    border: solid 1px #538312;
    background: #64991e;
    background: -webkit-gradient(linear, left top, left bottom, from(#7db72f), to(#4e7d0e));
    background: -moz-linear-gradient(top,  #7db72f,  #4e7d0e);
    filter:  progid:DXImageTransform.Microsoft.gradient(startColorstr='#7db72f', endColorstr='#4e7d0e');
}
.green:hover {
    background: #538018;
    background: -webkit-gradient(linear, left top, left bottom, from(#6b9d28), to(#436b0c));
    background: -moz-linear-gradient(top,  #6b9d28,  #436b0c);
    filter:  progid:DXImageTransform.Microsoft.gradient(startColorstr='#6b9d28', endColorstr='#436b0c');
}
.green:active {
    color: #a9c08c;
    background: -webkit-gradient(linear, left top, left bottom, from(#4e7d0e), to(#7db72f));
    background: -moz-linear-gradient(top,  #4e7d0e,  #7db72f);
    filter:  progid:DXImageTransform.Microsoft.gradient(startColorstr='#4e7d0e', endColorstr='#7db72f');
}

.circle {
        width:20px;
        height:20px;
        display:block;
        border-radius:66px;
        -moz-border-radius:66px;
        -webkit-border-radius:66px;
        -khtml-border-radius:66px;
        border:#ccc 1px ;
        font-size:12px;
        line-height:20px;
        text-shadow:0 1px 0 #fff;
        text-decoration:none;
        text-align:center;
        padding: 0 0 0;

}

    </style>

    <window title="All Buttons" border="normal">
   
        <grid width="450px" sclass="GridLayoutNoBorder">
            <columns>
                <column label="Buttons" />
                <column label="Description" />
            </columns>
            <rows>
                <row>
                    <button mold="os" label="Submit" onClick="" />
                    <label value="Default Os Mold. No CSS Override " />
                </row>
                <row>
                    <button mold="trendy" label="Submit" onClick="" />
                    <label value="Default Trendy Mold. No CSS Override" />
                </row>
                <row>
                    <div class="btndiv">
                        <button mold="trendy" label="Submit"
                            sclass="myGreen" onClick="" />
                    </div>
                    <label value="Mouse over image change" />
                </row>
                <row>
                <hlayout style="float:left;padding:8px;">
                    <a label="Save" id="saveTemplate" sclass="cw-notes-header-btn" />
                </hlayout>
                    <label value="Not using button component, Using anchor button. No Image used. " />
                </row>
                <row>
                <hlayout style="float:left;padding:8px;">
                    <a label="Save" id="saveTemplate1" sclass="rounded_corner" />
                </hlayout>
                    <label value="Not using button component, Using anchor button. No Image used. Rounded corner" />
                </row>
                <row>
                    <button mold="trendy" sclass="mybutton button green bigrounded" label="Submit" onClick="" />
                    <label value="Trendy Mold. CSS green bigrounded" />
                </row>
                <row>
                    <button mold="trendy" sclass="mybutton button green" label="Submit" onClick="" />
                    <label value="Trendy Mold. CSS green normal" />
                </row>
                <row>
                    <button mold="trendy" sclass="mybutton button green medium" label="Submit" onClick="" />
                    <label value="Trendy Mold. CSS green medium" />
                </row>
                <row>
                    <button mold="trendy" sclass="mybutton button green small" label="Submit" onClick="" />
                    <label value="Trendy Mold. CSS green Small" />
                </row>
                <row>
                    <button mold="trendy" sclass="mybutton button green circle" label="Submit" onClick="" />
                    <label value="Trendy Mold. CSS green Small" />
                </row>

            </rows>
        </grid>
    </window>
</zk>

Email ThisBlogThis!Share to XShare to Facebook
Posted in ZK CSS | No comments
Newer Post Older Post Home

0 comments:

Post a Comment

Subscribe to: Post Comments (Atom)

Popular Posts

  • ZK Example for inline Editing with Add New and Delete
    I am quite impressed on this demo from ZK . But adding new record and delete existing record is missing as part of typical CRUD. So i thoug...
  • ZK Passing Parameter between two files using MVVM–Part 1
    Overview This is the first series of articles about Passing parameter between two zul files using MVVM Design pattern .This article will fo...
  • Hibernate Validator Example 2
    In this example, we will see some more validation constraints such as @email, @past, @length, etc. And also we will also define custom error...
  • ViewModel Class Java Annotation @Init, @NotifyChange, @Command
    In following sections we'll list all syntaxes that can be used in implementing a ViewModel and applying ZK bind annotation. The ZK binde...
  • History of Present Illness
    HPI - One of the main component of Clinical History. What is an HPI ? The history of present illness (HPI) is a chronological description...
  • ZK Border Layout–Another example
    This examples show how you can use ZK Border Layout to show the product information on clicking image. ZK Version 6 Project Name : BorderL...
  • Good Website Design Links
    Form Design Label Placement in Forms International Address Fields in Web Forms 40 Eye-Catching Registration Pages blog-comment-form-...
  • How to refer CSS File in ZK Style tag
    In this example, we will see how to create CSS file as separate file and include in zul file to change the look and feel Project structure a...
  • ZK MVVM Form Binding CRUD with Spring and Hibernate - Part 4
    Presentation Layer using ZK Framework          In part 3 , We have completed Spring integration with hibernate. In this post, we will des...
  • Load Tab box Content on Demand Using MVVM
    ZK Version : 6.5.0 CE In this post, let us see how we can load individual ZUL File on each tab box content Step : 1 First let us create indi...

Categories

  • Billing Process
  • C Workbook
  • C++ Workbook
  • Eclipse Tips
  • EDI 5010
  • EMR Appointment Features
  • EMR Labs Stuff
  • EMR PMS Links
  • EMR Use cases
  • EMR Vital Sign
  • Good Website Design
  • Hibernate Criteria Queries
  • Hibernate Introduction
  • Hibernate Introduction Setup
  • Hibernate Mapping
  • Hibernate POC
  • Hibernate Validator
  • Hibernate–Java Environment setup
  • HPI
  • Java
  • Maven
  • MU Certification
  • NPI
  • PQRS
  • Practice Management System
  • Spring Security
  • Tech Links
  • Today Tech Stuff
  • zk
  • ZK Hibernate
  • ZK 5 Databinding
  • ZK Application
  • ZK Calling Another ZUL
  • ZK CheckBox
  • ZK CreateComponents
  • ZK CSS
  • ZK extended Components
  • ZK Foreach
  • ZK Forum Posts
  • ZK Framework
  • ZK Hibernate Setup
  • ZK ID Space
  • ZK Include
  • ZK Installation
  • ZK iReport
  • ZK Layout
  • ZK Listitem Pagination
  • ZK Message Box
  • ZK MVC
  • ZK MVC Combox Box
  • ZK MVC CRUD Examples
  • ZK MVC Listbox
  • ZK MVVM
  • ZK MVVM Combo
  • ZK MVVM CRUD
  • ZK MVVM ListBox
  • ZK Spring
  • ZK TextBox

Blog Archive

  • ►  2013 (105)
    • ►  December (3)
    • ►  September (7)
    • ►  August (13)
    • ►  July (1)
    • ►  June (11)
    • ►  May (3)
    • ►  April (14)
    • ►  March (19)
    • ►  February (21)
    • ►  January (13)
  • ▼  2012 (177)
    • ►  December (1)
    • ►  November (13)
    • ▼  October (19)
      • Form Fields Layout
      • EMR and PMS Links
      • ZK Search Text Box
      • ZK MVVM CRUD Without DB Connection - Part 6
      • ZK MVVM CRUD Without DB Connection
      • ZK MVVM CRUD Without DB Connection - Part 5
      • ZK Button CSS Customization
      • ZK Modal window CSS Customization
      • Button on Focus underline the text
      • ZK MVVM CRUD Without DB Connection - Part 4
      • ZK List Item CSS with sclass and Default ZK CSS fo...
      • ZK MVVM CRUD Without DB Connection - Part 2
      • ZK MVVM CRUD Without DB Connection - Part 3
      • ZK MVVM CRUD Without DB Connection - Part 1
      • Good Website Design Links
      • ZK Panel CSS Customization
      • History of Present Illness
      • EMR Use cases
      • Java Static Import
    • ►  September (24)
    • ►  August (26)
    • ►  July (6)
    • ►  June (37)
    • ►  May (30)
    • ►  April (16)
    • ►  March (1)
    • ►  January (4)
  • ►  2011 (5)
    • ►  December (1)
    • ►  November (1)
    • ►  July (1)
    • ►  June (1)
    • ►  April (1)
  • ►  2010 (1)
    • ►  September (1)
Powered by Blogger.

About Me

Unknown
View my complete profile