VGUI SectionedListPanel: Difference between revisions
m (Vgui ListPanel moved to Vgui SectionedListPanel) |
No edit summary |
||
Line 1: | Line 1: | ||
A | A SectionedListPanel is a vgui2 element defined in the vgui_controls library, in the file SectionedListPanel.cpp. SectionedListPanels are available in all source games. SectionedListPanels, as the name suggests, are useful for listing sectioned groups of information. The standard scoreboard was created using a SectionedListPanel, and thus represents a good example of the SectionedListPanel's capabilities. | ||
[[Image: | [[Image:SectionedListPanel.jpg|thumb|This screenshot represents valve's default scoreboard which was built using a SectionedListPanel.]] | ||
== Example Usage == | == Example Usage == | ||
Before creating | Before creating anything, we first need to include the SectionedListPanel header file. | ||
#include <vgui_controls/SectionedListPanel.h> | #include <vgui_controls/SectionedListPanel.h> | ||
SectionedListPanels can be created via the c++ keyword new with a simple call to SectionedListPanel. | |||
vgui::SectionedListPanel* | vgui::SectionedListPanel* myPanel = new SectionedListPanel(this, "myPanel"); | ||
Todo: I'm not going to go much further, as this is all I know about ListPanels. More information and examples can be found by simply looking at the scoreboard code, found in ClientScoreBoardDialog.cpp in the game_controls folder. | Todo: I'm not going to go much further, as this is all I know about ListPanels. More information and examples can be found by simply looking at the scoreboard code, found in ClientScoreBoardDialog.cpp in the game_controls folder. | ||
[[Category:VGUI_Controls|L]] | [[Category:VGUI_Controls|L]] |
Revision as of 15:48, 6 June 2009
A SectionedListPanel is a vgui2 element defined in the vgui_controls library, in the file SectionedListPanel.cpp. SectionedListPanels are available in all source games. SectionedListPanels, as the name suggests, are useful for listing sectioned groups of information. The standard scoreboard was created using a SectionedListPanel, and thus represents a good example of the SectionedListPanel's capabilities.
Example Usage
Before creating anything, we first need to include the SectionedListPanel header file.
#include <vgui_controls/SectionedListPanel.h>
SectionedListPanels can be created via the c++ keyword new with a simple call to SectionedListPanel.
vgui::SectionedListPanel* myPanel = new SectionedListPanel(this, "myPanel");
Todo: I'm not going to go much further, as this is all I know about ListPanels. More information and examples can be found by simply looking at the scoreboard code, found in ClientScoreBoardDialog.cpp in the game_controls folder.