Archive

Posts Tagged ‘grid header icon’

The Icon in the header of the Grid object, part two

June 5th, 2012 No comments

Some time ago I wrote about how it is possible to set the icon in the header of the grid object. On that occasion, to initiate setting up icons in a specific column used ID attribute column. The disadvantage of this approach is that if you have multiple grid objects that have columns that are repeated have to change the value of the ID attribute and therefore you are adding a new style in the CSS.

To overcome this problem, it is necessary to define a CSS style as a class, and then in the definition of the column to use CLS attribute. Example of setting ikoice would be:

.colFlag .x-column-header-inner
{
    background:transparent url(../../images/icons/famfam/flag_red.png)
    no-repeat 3px 3px !important;
    text-indent:-250px;
}

And then when defining attribute of the column grid object set, eg .:

	
{
    dataIndex:'idTip',
    align:'center',
    header:'Naziv kolone',
    width:24,
    hideable:false,
    menuDisabled:true,
    cls:'colFlag',
    tooltip:'Tekst koji se vidi ukoliko se koristi header tooltip plugin',
}

(srpski) ExtJS 4: Ikonica u zaglavlju Grid objekta

November 13th, 2011 No comments

Sorry, this entry is only available in Serbian.