-
3 Dec 2010 7:37 AM #21
The "style" method doesn't work. Can you show me how I might use the FitToParent plugin with the above code? For example, with the FitToParent plugin, it seems you have to specify the element, but in this case, we are using "renderTarget". Would "td:nth(10)" be the "element" in this case?
Also, where do I download it from? Thanks.
-
3 Dec 2010 7:41 AM #22Sencha - Community Support Team
- Join Date
- Mar 2007
- Location
- The Netherlands
- Posts
- 24,251
- Vote Rating
- 41
If you don't specify a target for FitToParent, it will use the element the component is rendered to (which would be the renderTarget).
-
3 Dec 2010 10:44 AM #23
This almost works! It properly sets the height of the panel to fill the entire space, however, and this is a big issue. Even though I have set autoScroll: true, no scrollbars appear, rather, the panel keeps growing as more html is added.
I really need the panel to maintain the height of the parent, while also showing vertical scrollbar as needed. Is this possible?
-
3 Dec 2010 1:59 PM #24
I was able to accomplish what I needed by embedding another panel within the panel that is using the FitToParent plugin. It works, but I really don't like the extra weight it brings.
-
1 Jan 2011 8:32 AM #25
How can you set the style of a particular TD in the html table at run time? For example, I want to set the background-color to #FF0000 for "td:nth(1)". How would I accomplish this in code? Thanks.
-
1 Jan 2011 9:13 AM #26Sencha - Community Support Team
- Join Date
- Mar 2007
- Location
- The Netherlands
- Posts
- 24,251
- Vote Rating
- 41
And you you applying or rendering something to that td?
-
1 Jan 2011 9:32 AM #27
Not currently. It is simply an empty TD which will have some background color depending on the state of that row during run time.
-
2 Jan 2011 1:44 PM #28
Sorry to bug, but any word on being able to do this?
-
2 Jan 2011 11:21 PM #29Sencha - Community Support Team
- Join Date
- Mar 2007
- Location
- The Netherlands
- Posts
- 24,251
- Vote Rating
- 41
So this is completely unrelated to HtmlLayout? You just want to give a particular td a black background?
Code:Ext.select('td:nth(1)').setStyle('backgroundColor', 'black');
-
3 Jan 2011 8:51 AM #30
yes, this is related to HtmlLayout, as I'm using that for a Layout of a panel. It's just that this particular TD is only visual, there is nothing rendered to it. However, the above code does not seem to work. No error, but it doesn't change the background color of that cell to black. Any idea what I'm doing wrong?


Reply With Quote