<!-- <questionid="arch-what"> Whatisthisprojectgoodfor? <hint> Pleaseprovideherefewlinesdescribingthetheproject, whatproblemitshouldsolve,providelinkstodocumentation, specifications,etc. </hint> </question>
-->
<answer id="arch-what">
The tab control is a swing control used by NetBeans window system, similar in function to a JTabbedPane, which
allows the user to see and select tabs that contain different components. It defines two GUI components:
TabbedContainer (similar to JTabbedPane) and TabDisplayer, a generic component for displaying tabs which
is not associated with any particular container. Several different types of UIs (view, editor, sliding)
are provided, each of which is handled by a different UI delegate class; UI delegate subclasses designed
to fit with Windows, Metal, Aqua and GTK look and feels are provided.
<api name="TabbedContainerAPI"type="export" category="friend"url="@TOP@/org/netbeans/swing/tabcontrol/TabbedContainer.html" group="java"/><br/>
<api name="PopupSwitcherAPI"type="export" category="friend"url="@TOP@/org/netbeans/swing/popupswitcher/package-summary.html" group="java">
API contains classes used only by <em>switchers</em> accessible through main menu in "Window/Documents..."
and "Go To/Recent Document". Besides this module the package is used from core/windows too.
Classes contained in the package are rather
general and therefore this package could be moved in the future. It is placed here only due to current
modules dependencies. Consequently the package is not intended for external use.<br/> For more
information on <code>SwitcherTable</code> and <code>SwitcherTableItem</code> see a javadoc.
</api>
</answer>
<!-- <questionid="compat-i18n"> Isyourmodulecorrectlyinternationalized? <hint> Correctinternationalizationmeansthatitobeysinstuctions at<ahref="http://www.netbeans.org/download/dev/javadoc/org-openide-modules/org/openide/modules/doc-files/i18n-branding.html"> NetBeansI18Npages</a>. </hint> </question>
-->
<answer id="compat-i18n">
Non-applicable - code that uses the tabbed container may provide localized strings for it to display. It has none of its own.
</answer>
<!-- <questionid="dep-nb"> WhatotherNetBeansprojectsdoesthisonedependon? <hint> Ifyouwant,describesuchprojectsasimportedAPIusing the<code><apiname="identification"type="importorexport"category="stable"url="whereisthedescription"/></code> </hint> </question>
-->
<answer id="dep-nb">
None, it is a standalone library that could be used in other
applications.
</answer>
<!-- <questionid="dep-platform"> Onwhichplatformsdoesyourmodulerun?Doesitruninthesame wayoneach? <hint> IfyourmoduleisusingJNIordealswithspecialdifferencesof OSeslikefilesystems,etc.pleasedescribeherewhattheyare. </hint> </question>
-->
<answer id="dep-platform">
Should be platform-independent, as it is just a Swing component.
</answer>
<!-- <questionid="deploy-jar"> DoyoudeployjustmoduleJARfile(s)orotherfilesaswell? <hint> IfyourmoduleconsistjustfromonemoduleJARfile,justconfirmthat. IfitusesmorethanoneJAR,describewheretherearelocated,how theyrefertoeachother. IfitconsistofmoduleJAR(s)andotherfiles,pleasedescribe whatistheirpurpose,whyotherfilesarenecessary.Please makesurethatinstallation/deinstallationleavesthesystem instateasitwasbeforeinstallation. </hint> </question>
-->
<answer id="deploy-jar">
Just a JAR.
</answer>
<!-- <questionid="deploy-packages"> Arepackagesofyourmodulemadeinaccessiblebynotdeclaringthem public? <hint> NetBeansmodulesystemallowsrestrictionofaccessrightsto publicclassesofyourmodulefromothermodules.Thisprevents unwanteddependenciesofothersonyourcodeandshouldbeused wheneverpossible(<ahref="http://www.netbeans.org/download/apis/org/openide/doc-files/upgrade.html#3.4-public-packages"> publicpackages </a>). </hint> </question>
-->
<answer id="deploy-packages">
No. There are three relevant packages - API for the tab control and tab displayer control,
an "event" package for logical separation, and a third package which provides an SPI
for alternate UI delegate implementation (however unlikely it is that a look and feel author
will take the time to write a custom UI delegate for NetBeans windowing system).
</answer>
<!-- <questionid="exec-component"> Isexecutionofyourcodeinfluencedbyany(string)property ofanyofyourcomponents? <hint> Often<code>JComponent.getClientProperty</code>,<code>Action.getValue</code> or<code>PropertyDescriptor.getValue</code>,etc.areusedtoinfluence abehaviourofsomecode.Thisofcourseformsaninterfacethatshould bedocumented.Alsoifonedependsonsomeinterfacethatanobject implements(<code>componentinstanceofRunnable</code>)thatformsan APIaswell. </hint> </question>
-->
<answer id="exec-component">
There is an "orientation" property which is honored by one of the three
UI types to display tabs on the sides or bottom of the container. It is a client
property, since it is optional for the UI delegate to implement this functionality
and only one UI type has a requirement for this behavior.
<!-- <questionid="exec-property"> Isexecutionofyourcodeinfluencedbyanyenvironmentor Javasystem(<code>System.getProperty</code>)property? <hint> Ifthereisapropertythatcanchangethebehaviourofyour code,somebodywilllikelyuseit.Youshoulddescribewhatitdoes andthestabilitycategoryofthisAPI.Youmayuse <pre> <propertyname="id"category="private"> descriptionoftheproperty,whereitisused,whatitinfluence,etc. </property> </pre> </hint> </question>
-->
<answer id="exec-property">
<api category="devel" group="systemproperty" name="nb.tabs.suppressCloseButton"type="export">
<p>
The system property <code>nb.tabs.suppressCloseButton</code>
can be used to hide close buttons by default.
</p>
</api>
<api category="devel" group="systemproperty" name="winsys.stretching_view_tabs"type="export">
<p>
The system property <code>winsys.stretching_view_tabs</code>
can be used to switch to stretching tab layout as implemented
in NetBeans version7.0 and older.
</p>
</api>
</answer>
<!-- <questionid="perf-limit"> Arethereanyhardcodedorpracticallimitsinthenumberorsizeof elementsyourcodecanhandle? </question>
-->
<answer id="perf-limit">
No. Different GUI types have different scalability characterisitics, in
accordance with their intended uses - editor tabs are designed to be
very lightweight and scalable, as there may be many; view tabs are less
scalable (but the ui design for view tabs also doesn't scale - all tabs
are displayed in a row and clipped if they don't fit); sliding tabs,
actually create one JButton per tab, making them the least scalable.
</answer>
<!-- <questionid="perf-mem"> Howmuchmemorydoesyourcomponentconsume?Estimate witharelationtothenumberofwindows,etc. </question>
-->
<answer id="perf-mem">
Not measured. No more than a similar usage of JTabbedPane, possibly less,
discounting for the higher number of classes loaded.
</answer>
<!-- <questionid="perf-scale"> Whichexternalcriteriainfluencetheperformanceofyour program(sizeoffileineditor,numberoffilesinmenu, insourcedirectory,etc.)andhowwellyourcodescales? Pleaseincludesomeestimates. </question>
-->
<answer id="perf-scale">
Availability of hardware graphics acceleration to Java2D on look and
feels other than Metal, some of which use GradientPaint and AlphaComposite
and BufferedImage objects.
</answer>
<!-- <questionid="exec-introspection"> Doesyourmoduleuseanykindofruntimetypeinformation(<code>instanceof</code>, workwith<code>java.lang.Class</code>,etc.)? <hint> CheckforcaseswhenyouhaveanobjectoftypeAandyoualso expectitto(possibly)beoftypeBanddosomespecialaction.That shouldbedocumented.Thesameappliesonoperationsinmeta-level (Class.isInstance(...),Class.isAssignableFrom(...),etc.). </hint> </question>
-->
<answer id="exec-introspection">
The displayed tabs are contained in a data model provided by the client.
The "user object" of each element in the model may be a
Component instance, or something else (in which case the client code must
supply a ComponentConverter instance to find the correct component when
an element is selected). The default implementation tests if the user
object is a Component (which it always should be currently for NetBeans
window system - a system of lazy loading of opened components based on ID's may be implemented in the future), and if it is not, returns null.
</answer>
<answer id="arch-overall">
The Swing components in this package were carefully designed to be consistent with standard Swing components in their
function, usage and ui registration mechanisms.
</answer>
<answer id="arch-quality">
Unit tests for the assorted data models involved are included.
</answer>
<answer id="arch-usecases">
Primary use cases are in the NetBeans window system, as top level containers in the main window; future use cases include providing a consistent UI for tabs in the property sheet, the component inspector and the output window, but
this probably will not happen for 4.0.
</answer>
<answer id="exec-threading">
All access must be on the AWT thread; this is enforced with assertions in some cases.
</answer>
<answer id="perf-spi">
It is highly unlikely that any look and feel will provide its own UI delegates for the tab control.
In the event that they do, it is up to the look and feel author to ensure adequate performance.
</answer>
Die Informationen auf dieser Webseite wurden
nach bestem Wissen sorgfältig zusammengestellt. Es wird jedoch weder Vollständigkeit, noch Richtigkeit,
noch Qualität der bereit gestellten Informationen zugesichert.
Bemerkung:
Die farbliche Syntaxdarstellung und die Messung sind noch experimentell.