This sample is located in \Samples\afc11\Viewers.
Description
Using the Sample
Key Project Files
Technologies Demonstrated
This sample shows how to use the most common AFC viewers. The sample displays a panel that contains the following components:
All the viewers that compose this sample are contained in a UITabViewer, which is, in turn, contained in a UIGroup control.
To use the sample
You can manipulate the sample's components by performing the following actions:
Use the mouse to select and move the gray splitter bars dividing the blocks of color, altering their dimensions and creating your own Mondrian-style painting. Colors from the color grid on the right can be dragged and dropped onto one of the panes of the split panel on the left. This functionality is provided by the classes in the com.ms.object and com.ms.object.dragdrop packages. An AWT component must implement the DragHandler interface (and be addNotified) so that the drag session is registered for com.ms.ui components.
This tab contains three columns: the first column contains a UITree control, and the next two contain UIText controls. The columns can be moved and resized. Clicking the plus signs expand the UITree; clicking the minus signs collapse the tree. Upon expansion, the viewer that contains the tree automatically adds horizontal and vertical scroll bars.
This tab displays two UIMarquees that have been extended to perform custom operations. The first marquee shows scrolling and changing statics moving vertically. The second marquee shows an animated graphic being moved down the page and to the right.
This tab uses complex navigation through nested tabs and tab viewers. Navigate through the tabs to discover the final image.
This class extends UIPanel and implements SDKConsts and IFxGraphicsConstants. It creates the UISplitViewer property page, which illustrates drag-and-drop functionality.
ColumnViewerPanel.javaThis class extends UIPanel and implements SDKConsts. It creates the UIColumnViewer property page, which illustrates column movement and tree expanding and collapsing.
MarqueePanel.javaThis class extends UIPanel and implements SDKConsts. It creates the UIMarquee property page, which illustrates scrolling, changing, and animation of graphics.
TabViewerPanel.javaThis class extends UIPanel and implements SDKConsts. It creates the UITabViewer property page, which illustrates nested tabs.