[CLOSED] How to set my own icons to a Panel and TreePanel?

  1. #1

    [CLOSED] How to set my own icons to a Panel and TreePanel?

    Hi,

    Could you tell me please how to set my own icons to a Panel and TreePanel?

  2. #2

    RE: [CLOSED] How to set my own icons to a Panel and TreePanel?

    Hi,

    Use IconCls property


    iconCls : String<div class="mdesc" style="margin-top: 0px; margin-right: 0px; margin-bottom: 0px; margin-left: 0px; padding-top: 5px; padding-right: 0px; padding-bottom: 5px; padding-left: 0px; color: rgb(68, 68, 68); "><div class="long" style="margin-top: 0px; margin-right: 0px; margin-bottom: 0px; margin-left: 0px; padding-top: 0px; padding-right: 0px; padding-bottom: 0px; padding-left: 0px; display: block; line-height: 18px; ">The CSS class selector that specifies a background image to be used as the header icon (defaults to '').<p style="margin-top: 0px; margin-right: 0px; margin-bottom: 0px; margin-left: 0px; padding-top: 0px; padding-right: 0px; padding-bottom: 0px; padding-left: 0px; ">An example of specifying a custom icon class would be something like:</p><code style="font-style: normal; font-weight: normal; font-size: 12px; color: rgb(0, 0, 0); line-height: 16px !important; font-family: 'Lucida Console', 'Courier New', Courier, monospace; "><i style="font-weight: normal; font-style: normal; color: rgb(153, 153, 153); ">// specify the property <b style="font-weight: normal; color: rgb(153, 153, 153); font-style: normal; ">in[/b] the config <b style="font-weight: normal; color: rgb(153, 153, 153); font-style: normal; ">for[/b] the class:[/i]
    ...
    iconCls: <em style="font-style: normal; font-weight: normal; color: rgb(0, 128, 128); background-color: rgb(238, 238, 238); ">'my-icon'[/i]

    <i style="font-weight: normal; font-style: normal; color: rgb(153, 153, 153); ">// css class that specifies background image to be used as the icon image: [/i]
    </code>

    .my-icon { background-image: url(../images/my-icon.gif) 0 6px no-repeat !important; }

Similar Threads

  1. [OPEN] [#167] TreePanel hide icons?
    By Timothy in forum 1.x Legacy Premium Help
    Replies: 8
    Last Post: Mar 13, 2013, 12:49 PM
  2. [CLOSED] Customize icons in TreePanel
    By bakardi in forum 1.x Legacy Premium Help
    Replies: 1
    Last Post: Apr 19, 2012, 12:30 PM
  3. Replies: 5
    Last Post: Mar 23, 2011, 9:57 AM
  4. [CLOSED] TreePanel Example not working with custom Icons
    By randy85253 in forum 1.x Legacy Premium Help
    Replies: 3
    Last Post: Jun 16, 2009, 11:21 PM
  5. [CLOSED] Custom TreeNode Icons for a dynamic TreePanel
    By conman in forum 1.x Legacy Premium Help
    Replies: 2
    Last Post: Jan 15, 2009, 10:22 AM

Posting Permissions