Re: [問題] ZK listbox 如何顯示 scroll bar
※ 引述《wxyy (裝笑幃)》之銘言:
: 底下這段
: <window height="120px" border="normal">
: <hbox height="100%">
: <listbox height="120px"> <!-- 高度:120px 有 scroll bar -->
: <listitem forEach="a, b, c, d, e, f, g" label="${each}"/>
: </listbox>
: <listbox height="100%"> <!-- 高度: 100% 沒有 scroll bar -->
: <listitem forEach="1, 2, 3, 4, 5, 6, 7" label="${each}" />
: </listbox>
: </hbox>
: </window>
: 顯示結果
: http://ppt.cc/uYr1
: 我想用高度 100% 的 listbox, 要如何才能正確的顯示 scroll bar ???
因為 ZK 有真正去算 Component 的 Size 的屬性是 hflex/vflex,
用 % width/height 的話只是簡單的給在 root element 上面,
建議使用 hflex/vflex 取代百分比的 width/height,
參考資料
http://books.zkoss.org/wiki/ZK_Developer's_Reference/UI_Patterns/Hflex_and_Vflex
縮
http://ppt.cc/cX2j
sample at zkfiddle
http://zkfiddle.org/sample/2ovduhc/2-ZK-listbox-size-scroll
--
※ 發信站: 批踢踢實業坊(ptt.cc)
◆ From: 118.168.1.69
→
12/11 01:00, , 1F
12/11 01:00, 1F
→
12/11 07:41, , 2F
12/11 07:41, 2F
推
12/11 10:40, , 3F
12/11 10:40, 3F
討論串 (同標題文章)
本文引述了以下文章的的內容:
完整討論串 (本文為第 2 之 2 篇):