GWT TabLayoutPanel does not display chart content

I have a structure similar to the following

<g:TabLayoutPanel ui:field="rightTabPanel" 
             width="100%" height="100%" 
                     barUnit="EM" barHeight="3"> 
    <g:tab> 
          <g:header>Graph</g:header> 
                    <g:FlowPanel ui:field="graphContent"/> 
     </g:tab> 
      <g:tab> 
           <g:header>Data</g:header> 
                      <g:FlowPanel ui:field="dataContent"/> 
     </g:tab> 
 </g:TabLayoutPanel> 

I have two tabs, of which a graph is shown, and the other shows data. However, the contents inside the tab are not displayed. If i put

<g:FlowPanel ui:field="graphContent"/>

outside TabLayoutPanel I can see the graph, but if I set it as shown above, the graph does not appear. Any key would be helpful. thanks in advance.

+3
source share
2 answers

For TabLayoutPanel to work properly, you need to ensure the following:

1) ( <! DOCTYPE html > )

2) Layout GWT 2.0 TabLayoutPanel.

TabLayoutPanel ( , ).

TabLayoutPanel * Layout. (, "div" ). , , * LayoutPanels (, DockLayoutPanel).

* LayoutPanel : TabPanel ( , ) TabLayoutPanel , TabPanel . , * LayoutPanels, .

CSS JavaScript, : : , .

+9

, , , , <g:TabPanel> <g:TabLayoutPanel>. , .

TabLayoutPanel, , TabPanel. TabLayoutPanel , . div, "" , TabPanel.

+5

Source: https://habr.com/ru/post/1766181/


All Articles