日韩性视频-久久久蜜桃-www中文字幕-在线中文字幕av-亚洲欧美一区二区三区四区-撸久久-香蕉视频一区-久久无码精品丰满人妻-国产高潮av-激情福利社-日韩av网址大全-国产精品久久999-日本五十路在线-性欧美在线-久久99精品波多结衣一区-男女午夜免费视频-黑人极品ⅴideos精品欧美棵-人人妻人人澡人人爽精品欧美一区-日韩一区在线看-欧美a级在线免费观看

歡迎訪問 生活随笔!

生活随笔

當(dāng)前位置: 首頁 > 编程资源 > 编程问答 >内容正文

编程问答

Wt::WTreeNode

發(fā)布時(shí)間:2025/3/8 编程问答 32 豆豆
生活随笔 收集整理的這篇文章主要介紹了 Wt::WTreeNode 小編覺得挺不錯(cuò)的,現(xiàn)在分享給大家,幫大家做個(gè)參考.

2019獨(dú)角獸企業(yè)重金招聘Python工程師標(biāo)準(zhǔn)>>>

A single node in a tree.

這個(gè) widget 渲染的是一棵樹的一個(gè)節(jié)點(diǎn)。

A tree list is constructed by combining several tree node objects in a tree hierarchy, by passing the parent tree node as the last argument in the child node constructor, or by using addChildNode(), to add a child to its parent.

一棵樹或者說一個(gè)樹表,由很多樹節(jié)點(diǎn)對(duì)象按一定的層次關(guān)系組合而成,可以先創(chuàng)建子節(jié)點(diǎn)然后告訴它誰是父節(jié)點(diǎn),或者創(chuàng)建父節(jié)點(diǎn),然后使用 addChildNode() 增加子節(jié)點(diǎn)。

Each tree node has a label, and optionally a label icon pair. The icon pair offers the capability to show a different icon depending on the state of the node (expanded or collapsed). When the node has any children, a child count may be displayed next to the label using setChildCountPolicy().

每個(gè)樹節(jié)點(diǎn)都有一個(gè) 標(biāo)簽,這個(gè)標(biāo)簽也可以用一對(duì)小圖標(biāo)代替。 這一對(duì)小圖標(biāo)具有根據(jù)節(jié)點(diǎn)打開/關(guān)閉狀態(tài)切換顯示的功能。當(dāng)某個(gè)節(jié)點(diǎn)含有子節(jié)點(diǎn)時(shí),可以通過 setChildCountPolicy() 來設(shè)置是否在父節(jié)點(diǎn)標(biāo)簽上顯示子節(jié)點(diǎn)的數(shù)量。

Expanding a tree node it will collapse all its children, so that a user may collapse/expand a node as a short-cut to collapsing all children.

擴(kuò)展開一個(gè)樹節(jié)點(diǎn)將顯示其所有下級(jí)子節(jié)點(diǎn)

The treenode provides several policies to communicate the current contents of the tree to the client (if possible):

樹節(jié)點(diǎn)與客戶端通訊的方式有如下幾種:

  • WTreeNode::PreLoading: the entire tree is transmitted to the client, and all tree navigation requires no further communication.
  • 一次全部載入,未來不用與服務(wù)器通訊。
  • WTreeNode::LazyLoading: only the minimum is transmitted to the client. When expanding a node for the first time, only then it is transmitted to the client, and this may thus have some latency.
  • 最小載入原則,當(dāng)?shù)谝淮螖U(kuò)展某個(gè)節(jié)點(diǎn)時(shí)才載入到客戶端,這顯然需要有載入時(shí)間。
  • WTreeNode::NextLevelLoading: all leafs of visible children are transmitted, but not their children. This provides a good trade-off between bandwith use and interactivity, since expanding any tree node will happen instantly, and at the same time trigger some communication in the back-ground to load the next level of invisible nodes.
  • 可見載入原則。這是一種平衡原則,當(dāng)前看不到的子節(jié)點(diǎn)不用載入,需要時(shí)才載入。

The default policy is WTreeNode::LazyLoading. Another load policy may be specified using setLoadPolicy() on the root node and before adding any children. The load policy is inherited by all children in the tree.

Wt 默認(rèn)的是最小載入原則,其他的可以通過 setLoadPolicy()? 對(duì)根節(jié)點(diǎn)定義,特別要注意必須是在添加子節(jié)點(diǎn)前定義。載入原則可以被所有子節(jié)點(diǎn)繼承。

There are a few scenarios where it makes sense to specialize the WTreeNode class. One scenario is create a tree that is populated dynamically while browsing. For this purpose you should reimplement the populate() method, whose default implementation does nothing. This method is called when 'loading' the node. The exact moment for loading a treenode depends on the LoadPolicy.

A second scenario that is if you want to customize the look of the tree label (see labelArea()) or if you want to modify or augment the event collapse/expand event handling (see doExpand() and doCollapse()).

〔節(jié)點(diǎn)的樣式可以自定義,通過labelArea() 擴(kuò)展當(dāng)前標(biāo)簽區(qū)域的內(nèi)容或動(dòng)作等,當(dāng)然擴(kuò)展或收起的事件處理也可以自定義,具體參考doExpand() 和 doCollapse()〕

See WTree for a usage example.

CSS

The tree is styled by the current CSS theme. The look can be overridden using the Wt-tree CSS class and the following selectors:

默認(rèn)樹節(jié)點(diǎn)的樣式采用 CSS theme 定義,我們可以重寫 Wt-tree 樣式類,如下:

.Wt-tree .Wt-trunk : vertical line, trunk
.Wt-tree .Wt-end : vertical line, last item
.Wt-tree .Wt-collapse : collapse icon (img *)
.Wt-tree .Wt-expand : expand icon (img *)
.Wt-tree .Wt-noexpand : leaf icon

.Wt-tree .Wt-label : the node label
.Wt-tree .Wt-childcount : the node child count * The collapse and expand icons are fetched themselves as images, nav-plus.gif and nav-minus.gif.

See also:
WTree, WTreeTableNode

類別: c++witty? 查看評(píng)論

轉(zhuǎn)載于:https://my.oschina.net/zhmsong/blog/5226

總結(jié)

以上是生活随笔為你收集整理的Wt::WTreeNode的全部內(nèi)容,希望文章能夠幫你解決所遇到的問題。

如果覺得生活随笔網(wǎng)站內(nèi)容還不錯(cuò),歡迎將生活随笔推薦給好友。

主站蜘蛛池模板: 91精品国产乱码在线观看 | 他趴在我两腿中间添得好爽在线看 | 国产午夜免费福利 | 国产成人精品一区二区 | 骚虎免费视频 | 欧美三级视频网站 | 日本一区二区高清视频 | 成人在线小视频 | 一区二区在线免费视频 | 夜色视频在线观看 | 国产91香蕉 | 精品国产乱码一区二 | 精品久久久蜜桃 | 黄色小说在线看 | 亚洲爽爆 | 欧美三级一区二区三区 | 香蕉网站视频 | 黑人番号| jizz精品 | 久草中文在线视频 | 亚洲福利av | 成人福利影院 | 欧美在线一区二区三区 | 777亚洲| 午夜影院 | 久久久香蕉 | 欧美第四页 | 午夜激情视频在线观看 | 天天操天天插天天干 | 午夜精品在线播放 | 欧亚免费视频 | 国产极品探花 | 久草最新视频 | 欧美日韩免费观看视频 | 日本丰满少妇裸体自慰 | 精品欧美一区二区三区在线观看 | 国产精品自拍亚洲 | 亚洲一级黄色大片 | 极品少妇xxxx精品少妇偷拍 | 国产成人亚洲综合a∨婷婷 台湾a级片 | 欧美精品卡一卡二 | 精品一区二区免费看 | 亚洲在线观看免费 | 不卡的中文字幕 | 日韩区欧美区 | 国产三级按摩推拿按摩 | 日本久久久久久久久 | 在线播放精品视频 | 福利视频二区 | 一级特黄欧美 | 欧美一区二区在线免费观看 | 国产男女无套免费网站 | 婷婷九月 | 免费在线观看的黄色网址 | 亚洲影视一区 | 五月激情开心网 | jzzijzzij亚洲成熟少妇18 欧美www在线观看 | 欧美黄色片免费看 | 欧美456| 黄色av网站免费 | 欧美久久久影院 | 亚洲嫩草影院 | 亚洲自拍色图 | 黄色av网站免费观看 | 欧美va亚洲va | 国产伦精品一区二区三区高清 | 免费小视频在线观看 | 高清国产一区 | 日韩电影一区二区三区 | 欧美字幕 | 国产日韩欧美综合 | 一区二区免费av | 永久免费成人代码 | 免费看60分钟黄视频 | 欧美区在线 | 色综合久久精品亚洲国产 | 亚洲欧美综合色 | 69影院少妇在线观看 | 猛男大粗猛爽h男人味 | 久久久99精品国产一区二区三区 | 老司机深夜福利网站 | 五月婷婷色丁香 | 精品一区二区免费 | 久久岛国 | 在线看黄网址 | 国产成人综合在线视频 | 97视频在线观看免费高清完整版在线观看 | 亚洲精品18 | 国产毛片毛片毛片毛片毛片毛片 | 91猎奇在线观看 | 日产精品久久久 | 97在线公开视频 | 人人干干人人 | 黄色图片小说 | 亚洲一二三四在线观看 | 天天插插插 | 国产视频一区二区三 | 亲子乱对白乱都乱了 | av毛片在线免费看 |