admin管理员组

文章数量:1025207

How I can change the individual region background color of viewport extjs 4. Here is my code.

{
    region: 'south',
    title: 'South Panel',
    collapsible: true,
    html: 'Information goes here',
    split: true,
    height: 100,
    minHeight: 100
}, {
    region: 'east',
    title: 'East Panel',
    collapsible: true,
    split: true,
    width: 150
}

Now tell me please.

How I can change the individual region background color of viewport extjs 4. Here is my code.

{
    region: 'south',
    title: 'South Panel',
    collapsible: true,
    html: 'Information goes here',
    split: true,
    height: 100,
    minHeight: 100
}, {
    region: 'east',
    title: 'East Panel',
    collapsible: true,
    split: true,
    width: 150
}

Now tell me please.

Share Improve this question asked Mar 27, 2012 at 6:46 AsifAsif 6479 silver badges18 bronze badges
Add a ment  | 

1 Answer 1

Reset to default 5

You can assign a class to the body using the bodyCls config then set the background-color via css. Alternatively, you can set the bodyStyle inline to a css string:

bodyCls: 'foo'
// or
bodyStyle: 'background-color: red;'

To do it dynamically, you can set the style on the body:

myPanel.body.setStyle('background-color', 'red');

How I can change the individual region background color of viewport extjs 4. Here is my code.

{
    region: 'south',
    title: 'South Panel',
    collapsible: true,
    html: 'Information goes here',
    split: true,
    height: 100,
    minHeight: 100
}, {
    region: 'east',
    title: 'East Panel',
    collapsible: true,
    split: true,
    width: 150
}

Now tell me please.

How I can change the individual region background color of viewport extjs 4. Here is my code.

{
    region: 'south',
    title: 'South Panel',
    collapsible: true,
    html: 'Information goes here',
    split: true,
    height: 100,
    minHeight: 100
}, {
    region: 'east',
    title: 'East Panel',
    collapsible: true,
    split: true,
    width: 150
}

Now tell me please.

Share Improve this question asked Mar 27, 2012 at 6:46 AsifAsif 6479 silver badges18 bronze badges
Add a ment  | 

1 Answer 1

Reset to default 5

You can assign a class to the body using the bodyCls config then set the background-color via css. Alternatively, you can set the bodyStyle inline to a css string:

bodyCls: 'foo'
// or
bodyStyle: 'background-color: red;'

To do it dynamically, you can set the style on the body:

myPanel.body.setStyle('background-color', 'red');

本文标签: javascripthow i can change color of viewport region extjs 4Stack Overflow