最新消息:Welcome to the puzzle paradise for programmers! Here, a well-designed puzzle awaits you. From code logic puzzles to algorithmic challenges, each level is closely centered on the programmer's expertise and skills. Whether you're a novice programmer or an experienced tech guru, you'll find your own challenges on this site. In the process of solving puzzles, you can not only exercise your thinking skills, but also deepen your understanding and application of programming knowledge. Come to start this puzzle journey full of wisdom and challenges, with many programmers to compete with each other and show your programming wisdom! Translated with DeepL.com (free version)

javascript - how i can change color of viewport region extjs 4? - Stack Overflow

matteradmin6PV0评论

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');
Post a comment

comment list (0)

  1. No comments so far