1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
133
134
135
136
137
138
139
140
141
142
143
144
145
146
147
148
149
150
151
152
153
154
155
156
157
158
159
160
161
162
163
164
165
166
167
168
169
170
171
172
173
174
175
176
177
178
179
180
181
182
183
184
185
186
187
188
189
190
191
192
193
194
195
|
---
title: tab
slug: Archive/Mozilla/XUL/tab
tags:
- XUL Elemente
- XUL Referenz
translation_of: Archive/Mozilla/XUL/tab
---
<div class="noinclude"><span class="breadcrumbs XULRef_breadcrumbs">
« <a href="/de/docs/XUL_Referenz">XUL Referenz Startseite</a> [
<a href="#Beispiele">Beispiele</a> |
<a href="#Attribute">Attribute</a> |
<a href="#Eigenschaften">Eigenschaften</a> |
<a href="#Methoden">Methoden</a> |
<a href="#Verwandte_Themen">Verwandte Themen</a> ]
</span></div>
<p>Steht für einen einzelnen Reiter innerhalb eines <code><a href="/de/docs/Mozilla/Tech/XUL/tabs" title="tabs">tabs</a></code>-Elements. Der Benutzer kann den Reiter klicken, um die Seite in den Vordergrund zu holen, die zu der <code><a href="/de/docs/Mozilla/Tech/XUL/tabbox" title="tabbox">tabbox</a></code> gehört.</p>
<p>Weitere Informationen im <a href="/de/XUL_Tutorial/Karteikarten" title="de/XUL_Tutorial/Karteikarten">XUL Tutorial</a>.</p>
<dl> <dt>Attribute</dt> <dd><a href="#a-accesskey">accesskey</a>, <a href="#a-afterselected">afterselected</a>, <a href="#a-beforeselected">beforeselected</a>, <a href="#a-command">command</a>, <a href="#a-crop">crop</a>, <a href="#a-disabled">disabled</a>, <a href="#a-first-tab">first-tab</a>, <a href="#a-image">image</a>, <a href="#a-label">label</a>, <a href="#a-last-tab">last-tab</a>, <a href="#a-linkedpanel">linkedpanel</a>, <a href="#a-oncommand">oncommand</a>, <a href="#a-pinned">pinned</a>, <a href="#a-tab.selected">selected</a>, <a href="#a-tabindex">tabindex</a>, <a href="#a-validate">validate</a>, <a href="#a-value">value</a></dd>
</dl>
<dl> <dt>Eigenschaften</dt> <dd><a href="#p-accessKey">accessKey</a>, <a href="#p-accessibleType">accessibleType</a>, <a href="#p-command">command</a>, <a href="#p-tab.control">control</a>, <a href="#p-crop">crop</a>, <a href="#p-disabled">disabled</a>, <a href="#p-image">image</a>, <a href="#p-label">label</a>, <a href="#p-linkedPanel">linkedPanel</a>, <a href="#p-selected">selected</a>, <a href="#p-tabIndex">tabIndex</a>, <a href="#p-value">value</a></dd>
</dl>
<h3 id="Beispiele" name="Beispiele">Beispiele</h3>
<p>(Beispiel benötigt)</p>
<h3 id="Attribute" name="Attribute">Attribute</h3>
<p> </p><div id="a-accesskey">
<dl> <dt><code id="a-accesskey"><a href="https://developer.mozilla.org/de/docs/Mozilla/Tech/XUL/Attribute/accesskey">accesskey</a></code></dt> <dd>Typ: <em>character</em></dd> <dd>Dem Attribut wird der Buchstabe zugewiesen, der als Tastenkürzel für das Element dienen soll. Dieser Buchstabe sollte sinnvollerweise innerhalb des Textes des Attributs <code><code id="a-label"><a href="https://developer.mozilla.org/de/docs/Mozilla/Tech/XUL/Attribute/label">label</a></code></code> des Elements vorkommen. </dd>
</dl>
</div> <div id="a-afterselected">
<dl>
<dt><code id="a-afterselected"><a href="https://developer.mozilla.org/en-US/docs/Mozilla/Tech/XUL/Attribute/afterselected">afterselected</a></code></dt>
<dd>Type: <em>boolean</em></dd>
<dd>This is set to <code>true</code> if the tab is immediately after the currently selected tab. This is automatically set when needed and you shouldn't adjust it manually. This is primarily useful for themes so that they can adjust the appearance of the area around the selected tab.</dd>
</dl>
</div> <div id="a-beforeselected">
<dl>
<dt><code id="a-beforeselected"><a href="https://developer.mozilla.org/en-US/docs/Mozilla/Tech/XUL/Attribute/beforeselected">beforeselected</a></code></dt>
<dd>Type: <em>boolean</em></dd>
<dd>This is set to <code>true</code> if the tab is immediately before the currently selected tab. This is set automatically set when needed and you shouldn't adjust it manually. This is primarily useful for themes so that they can adjust the appearance of the area around the selected tab.</dd>
</dl>
</div> <div id="a-crop">
<dl>
<dt>
<code id="a-crop"><a href="https://developer.mozilla.org/en-US/docs/Mozilla/Tech/XUL/Attribute/crop">crop</a></code></dt>
<dd>
Type: <em>one of the values below</em></dd>
<dd>
If the label of the element is too big to fit in its given space, the text will be cropped on the side specified by the <code>crop</code> attribute. An ellipsis will be used in place of the cropped text. If the box direction is reversed, the cropping is reversed.</dd>
<dd>
<dl>
<dt>
<code>start</code></dt>
<dd>
The text will be cropped on its left side in left-to-right text locales, and the right side in right-to-left locales.</dd>
<dt>
<code>end</code></dt>
<dd>
The text will be cropped on its right side in left-to-right text locales, and the right side in right-to-left locales.</dd>
<dt>
<code>left</code></dt>
<dd>
<span title="This deprecated API should no longer be used, but will probably still work."><i class="icon-thumbs-down-alt"> </i></span> The text will be cropped on its left side.</dd>
<dt>
<code>right</code></dt>
<dd>
<span title="This deprecated API should no longer be used, but will probably still work."><i class="icon-thumbs-down-alt"> </i></span> The text will be cropped on its right side.</dd>
<dt>
<code>center</code></dt>
<dd>
The text will be cropped in the middle, showing both the start and end of the text normally.</dd>
<dt>
<code>none</code></dt>
<dd>
The text will be not be cropped using an ellipsis. However, the text will simply be cut off if it is too large. The side depends on the CSS text alignment.</dd>
</dl>
</dd>
<dd>
Depending on the platform and theme being used, some elements will have set a maximum width so they will always appear cropped. If you wish to use the value <code>none</code> and the displayed text is larger than this maximum width, you may be able to use the max-width CSS property (or the maxwidth attribute) to override this size. For example, for a menuitem in a menu you can add the following CSS rule when you want to use the value <code>none</code>:</dd>
<dd>
<pre class="eval">menupopup > menuitem, menupopup > menu { max-width: none; }
</pre>
</dd>
</dl>
</div> <div id="a-disabled">
<dl> <dt><code id="a-disabled"><a href="https://developer.mozilla.org/de/docs/Mozilla/Tech/XUL/Attribute/disabled">disabled</a></code></dt> <dd>Typ: <em>boolean</em></dd> <dd>Kennzeichnet, ob ein Element deaktiviert ist oder nicht. Wenn das Element auf <code>true</code> gesetzt ist, ist das Element deaktiviert. Deaktivierte Elemente sind gewöhnlich mit einem grauen Text dargestellt. Wenn ein Element deaktiviert ist, wird es auf Anwenderaktionen nicht reagieren, es kann den Fokus nicht erlangen und das <code>command</code> Ereignis wird nicht ausgelöst. Das Element wird allerdings noch auf Mausereignisse antworten. Um das Element zu aktivieren, ist es besser das Attribut zu entfernen als es auf den Wert <code>false</code> zu setzen. Um den Wert dieses Attributs mittels JavaScript zu setzen oder abzurufen, sollte besser die <code><span><a href="https://developer.mozilla.org/de/docs/XUL/Eigenschaften/disabled">disabled</a></span></code> Eigenschaft verwendet werden.</dd>
</dl>
</div> <div id="a-first-tab">
<dl>
<dt><code id="a-first-tab"><a href="https://developer.mozilla.org/en-US/docs/Mozilla/Tech/XUL/Attribute/first-tab">first-tab</a></code></dt>
<dd>Type: <em>boolean</em></dd>
<dd>This attribute will be set to <code>true</code> for the first tab. This attribute should not be set manually, but is useful in a <a href="/en/Themes" title="en/Themes">theme</a> if the first tab should be styled differently.</dd>
</dl>
</div> <div id="a-image">
<dl>
<dt><code id="a-image"><a href="https://developer.mozilla.org/en-US/docs/Mozilla/Tech/XUL/Attribute/image">image</a></code></dt>
<dd>Type: <em>URI</em></dd>
<dd>The URI of the image to appear on the element. If this attribute is empty or left out, no image appears. The position of the image is determined by the <code id="a-dir"><a href="https://developer.mozilla.org/en-US/docs/Mozilla/Tech/XUL/Attribute/dir">dir</a></code> and <code id="a-orient"><a href="https://developer.mozilla.org/en-US/docs/Mozilla/Tech/XUL/Attribute/orient">orient</a></code> attributes.</dd>
</dl>
</div> <div id="a-label">
<dl> <dt><code id="a-label"><a href="https://developer.mozilla.org/de/docs/Mozilla/Tech/XUL/Attribute/label">label</a></code></dt> <dd>Typ: <em>string</em></dd> <dd>Die Beschriftung für das Element. Wird das Attribut nicht angegeben, so erscheint auch kein Beschriftungstext.</dd>
</dl>
</div> <div id="a-last-tab">
<dl>
<dt><code id="a-last-tab"><a href="https://developer.mozilla.org/en-US/docs/Mozilla/Tech/XUL/Attribute/last-tab">last-tab</a></code></dt>
<dd>Type: <em>boolean</em></dd>
<dd>This attribute will be set to <code>true</code> for the last tab. This attribute should not be set manually, but is useful in a <a href="/en/Themes" title="en/Themes">theme</a> if the last tab should be styled differently.</dd>
</dl>
</div> <div id="a-linkedpanel">
<dl>
<dt><code id="a-linkedpanel"><a href="https://developer.mozilla.org/en-US/docs/Mozilla/Tech/XUL/Attribute/linkedpanel">linkedpanel</a></code></dt>
<dd>Type: <em>id</em></dd>
<dd>The <code id="a-id"><a href="https://developer.mozilla.org/en-US/docs/Mozilla/Tech/XUL/Attribute/id">id</a></code> of the linked <code><a href="/en-US/docs/Mozilla/Tech/XUL/tabpanel" title="tabpanel">tabpanel</a></code> element that will be displayed when the tab is selected. If this attribute is not used, the tab will be connected to the panel at the corresponding index in the <code><a href="/en-US/docs/Mozilla/Tech/XUL/tabpanels" title="tabpanels">tabpanels</a></code> element that the <code><a href="/en-US/docs/Mozilla/Tech/XUL/tab" title="tab">tab</a></code> is in its <code><a href="/en-US/docs/Mozilla/Tech/XUL/tabs" title="tabs">tabs</a></code> container. However, if this attribute is used, this behavior is overridden, and the tab will always be linked to a specific panel. This might be used to avoid duplication by linking several tabs to one panel with slight differences to the content adjusted in the select event.</dd>
</dl>
</div> <div id="a-oncommand">
<dl>
<dt><code id="a-oncommand"><a href="https://developer.mozilla.org/en-US/docs/Mozilla/Tech/XUL/Attribute/oncommand">oncommand</a></code></dt>
<dd>Type: <em>script code</em></dd>
<dd>This event handler is called when the command is activated. This occurs when a user selects a menu item or presses a keyboard shortcut attached to the command.</dd>
</dl>
</div> <div id="a-pinned">
<dl> <dt><code id="a-pinned"><a href="https://developer.mozilla.org/en-US/docs/Mozilla/Tech/XUL/Attribute/pinned">pinned</a></code> </dt> <dd>Type: <em>boolean</em></dd> <dd>This attribute is set to <code>true</code> if the tab has been pinned (that is, if it's an app tab). The <code><a href="/en-US/docs/Mozilla/Tech/XUL/tabbrowser" title="tabbrowser">tabbrowser</a></code> element's <span id="m-pinTab"><code><a href="https://developer.mozilla.org/en-US/docs/Mozilla/Tech/XUL/Method/pinTab">pinTab</a></code></span> and <span id="m-unpinTab"><code><a href="https://developer.mozilla.org/en-US/docs/Mozilla/Tech/XUL/Method/unpinTab">unpinTab</a></code></span> methods handle pinning and unpinning tabs.</dd>
</dl>
</div> <div id="a-tab.selected">
<dl>
<dt><code id="a-tab.selected"><a href="https://developer.mozilla.org/en-US/docs/Mozilla/Tech/XUL/Attribute/tab.selected">selected</a></code></dt>
<dd>Type: <em>boolean</em></dd>
<dd>This attribute is set to <code>true</code> if the tab is selected by default.</dd>
</dl>
</div> <div id="a-tabindex">
<dl>
<dt><code id="a-tabindex"><a href="https://developer.mozilla.org/en-US/docs/Mozilla/Tech/XUL/Attribute/tabindex">tabindex</a></code></dt>
<dd>Type: <em>integer</em></dd>
<dd>The tab order of the element. The tab order is the order in which the focus is moved when the user presses the "<code>tab</code>" key. Elements with a higher <code>tabindex</code> are later in the tab sequence.</dd>
</dl>
</div> <div id="a-validate">
<dl>
<dt><code id="a-validate"><a href="https://developer.mozilla.org/en-US/docs/Mozilla/Tech/XUL/Attribute/validate">validate</a></code></dt>
<dd>Type: <em>one of the values below</em></dd>
<dd>This attribute indicates whether to load the image from the cache or not. This would be useful if the images are stored remotely or you plan on swapping the image frequently. The following values are accepted, or leave out the attribute entirely for default handling:</dd>
<dd>
<dl>
<dt><code>always</code></dt>
<dd>The image is always checked to see whether it should be reloaded.</dd>
<dt><code>never</code></dt>
<dd>The image will be loaded from the cache if possible.</dd>
</dl>
</dd>
</dl>
</div>
<h3 id="Eigenschaften" name="Eigenschaften">Eigenschaften</h3>
<p> </p><div id="p-accessKey"></div> <div id="p-accessibleType"></div> <div id="p-command"></div> <div id="p-tab.control"></div> <div id="p-crop"></div> <div id="p-disabled"></div> <div id="p-image"></div> <div id="p-label"></div> <div id="p-linkedPanel"></div> <div id="p-selected"></div> <div id="p-tabIndex"></div> <div id="p-value"></div>
<h3 id="Methoden" name="Methoden">Methoden</h3>
<table style="border: 1px solid rgb(204, 204, 204); margin: 0px 0px 10px 10px; padding: 0px 10px; background: rgb(238, 238, 238) none repeat scroll 0% 50%;"> <tbody> <tr> <td> <p><strong>Geerbte Methoden</strong><br> <small><code><a href="https://developer.mozilla.org/de/docs/DOM/element.element.addEventListener">element.addEventListener()</a></code>, <code><a href="https://developer.mozilla.org/de/docs/DOM/element.node.appendChild">node.appendChild()</a></code>, <span id="m-blur"><code><a href="https://developer.mozilla.org/de/docs/Mozilla/Tech/XUL/Methoden/blur">blur</a></code></span>, <span id="m-click"><code><a href="https://developer.mozilla.org/de/docs/Mozilla/Tech/XUL/Methoden/click">click</a></code></span>, <code><a href="https://developer.mozilla.org/de/docs/DOM/element.node.cloneNode">node.cloneNode()</a></code>, <code><a href="https://developer.mozilla.org/de/docs/DOM/element.node.compareDocumentPosition">node.compareDocumentPosition()</a></code>, <code><a href="https://developer.mozilla.org/de/docs/DOM/element.element.dispatchEvent">element.dispatchEvent()</a></code>, <span id="m-doCommand"><code><a href="https://developer.mozilla.org/de/docs/Mozilla/Tech/XUL/Methoden/doCommand">doCommand</a></code></span>, <span id="m-focus"><code><a href="https://developer.mozilla.org/de/docs/Mozilla/Tech/XUL/Methoden/focus">focus</a></code></span>, <code><a href="https://developer.mozilla.org/de/docs/DOM/element.element.getAttribute">element.getAttribute()</a></code>, <code><a href="https://developer.mozilla.org/de/docs/DOM/element.element.getAttributeNode">element.getAttributeNode()</a></code>, <code><a href="https://developer.mozilla.org/de/docs/DOM/element.element.getAttributeNodeNS">element.getAttributeNodeNS()</a></code>, <code><a href="https://developer.mozilla.org/de/docs/DOM/element.element.getAttributeNS">element.getAttributeNS()</a></code>, <code><a href="https://developer.mozilla.org/de/docs/DOM/element.element.getBoundingClientRect">element.getBoundingClientRect()</a></code>, <code><a href="https://developer.mozilla.org/de/docs/DOM/element.element.getClientRects">element.getClientRects()</a></code>, <span id="m-getElementsByAttribute"><code><a href="https://developer.mozilla.org/de/docs/Mozilla/Tech/XUL/Methoden/getElementsByAttribute">getElementsByAttribute</a></code></span>, <span id="m-getElementsByAttributeNS"><code><a href="https://developer.mozilla.org/de/docs/Mozilla/Tech/XUL/Methoden/getElementsByAttributeNS">getElementsByAttributeNS</a></code></span>, <code><a href="https://developer.mozilla.org/de/docs/DOM/element.element.getElementsByClassName">element.getElementsByClassName()</a></code>, <code><a href="https://developer.mozilla.org/de/docs/DOM/element.element.getElementsByTagName">element.getElementsByTagName()</a></code>, <code><a href="https://developer.mozilla.org/de/docs/DOM/element.element.getElementsByTagNameNS">element.getElementsByTagNameNS()</a></code>, <code><a href="https://developer.mozilla.org/de/docs/DOM/element.node.getFeature">node.getFeature()</a></code>, <code><a href="https://developer.mozilla.org/de/docs/DOM/element.node.getUserData">node.getUserData()</a></code>, <code><a href="https://developer.mozilla.org/de/docs/DOM/element.element.hasAttribute">element.hasAttribute()</a></code>, <code><a href="https://developer.mozilla.org/de/docs/DOM/element.element.hasAttributeNS">element.hasAttributeNS()</a></code>, <code><a href="https://developer.mozilla.org/de/docs/DOM/element.nodes.hasAttributes">nodes.hasAttributes()</a></code>, <code><a href="https://developer.mozilla.org/de/docs/DOM/element.nodes.hasChildNodes">nodes.hasChildNodes()</a></code>, <code><a href="https://developer.mozilla.org/de/docs/DOM/element.node.insertBefore">node.insertBefore()</a></code>, <code><a href="https://developer.mozilla.org/de/docs/DOM/element.node.isDefaultNamespace">node.isDefaultNamespace()</a></code>, <code><a href="https://developer.mozilla.org/de/docs/DOM/element.node.isEqualNode">node.isEqualNode()</a></code>, <code><a href="https://developer.mozilla.org/de/docs/DOM/element.node.isSameNode">node.isSameNode()</a></code>, <code><a href="https://developer.mozilla.org/de/docs/DOM/element.node.isSupported">node.isSupported()</a></code>, <code><a href="https://developer.mozilla.org/de/docs/DOM/element.node.lookupNamespaceURI">node.lookupNamespaceURI()</a></code>, <code><a href="https://developer.mozilla.org/de/docs/DOM/element.node.lookupPrefix">node.lookupPrefix()</a></code>, <code><a href="https://developer.mozilla.org/de/docs/DOM/element.node.normalize">node.normalize()</a></code>, <code><a href="https://developer.mozilla.org/de/docs/DOM/element.element.querySelector">element.querySelector()</a></code>, <code><a href="https://developer.mozilla.org/de/docs/DOM/element.element.querySelectorAll">element.querySelectorAll()</a></code>, <code><a href="https://developer.mozilla.org/de/docs/DOM/element.element.removeAttribute">element.removeAttribute()</a></code>, <code><a href="https://developer.mozilla.org/de/docs/DOM/element.element.removeAttributeNode">element.removeAttributeNode()</a></code>, <code><a href="https://developer.mozilla.org/de/docs/DOM/element.element.removeAttributeNS">element.removeAttributeNS()</a></code>, <code><a href="https://developer.mozilla.org/de/docs/DOM/element.node.removeChild">node.removeChild()</a></code>, <code><a href="https://developer.mozilla.org/de/docs/DOM/element.element.removeEventListener">element.removeEventListener()</a></code>, <code><a href="https://developer.mozilla.org/de/docs/DOM/element.node.replaceChild">node.replaceChild()</a></code>, <code><a href="https://developer.mozilla.org/de/docs/DOM/element.element.setAttribute">element.setAttribute()</a></code>, <code><a href="https://developer.mozilla.org/de/docs/DOM/element.element.setAttributeNode">element.setAttributeNode()</a></code>, <code><a href="https://developer.mozilla.org/de/docs/DOM/element.element.setAttributeNodeNS">element.setAttributeNodeNS()</a></code>, <code><a href="https://developer.mozilla.org/de/docs/DOM/element.element.setAttributeNS">element.setAttributeNS()</a></code>, <code><a href="https://developer.mozilla.org/de/docs/DOM/element.node.setUserData">node.setUserData()</a></code></small></p> </td> </tr> </tbody>
</table>
<h4 id="Probleme" name="Probleme">Probleme</h4>
<p>In Versionen vor Gecko 1.9 (Firefox 3.0) ist es nicht möglich, einen Reiter außer Kraft zu setzen. Der Reiter wird zwar "grau" dargestellt, akzeptiert jedoch Ereignisse. Dieses Verhalten wurde in Firefox 3 behoben.</p>
<p>Des weiteren führt ein Wiederanzeigen eines Reiters nach dem Verstecken zu einer unvorhersehbaren Anordnung der Reiter. Siehe <a href="https://bugzilla.mozilla.org/show_bug.cgi?id=307088" title="tab not responding if append to parent with hidden attribute">Bug 307088</a> und <a href="https://bugzilla.mozilla.org/show_bug.cgi?id=261826" title="FIXED: XUL tabs appear in wrong order, if a tab's HIDDEN attribute is set to TRUE then later revealed by either setting HIDDEN to FALSE or removing the HIDDEN attribute entirely.">Bug 261826</a>. (Es empfiehlt sich <a href="/de/XUL/Attribute/collapsed" title="de/XUL/Attribute/collapsed">collapsed</a> statt <a href="/de/XUL/Attribute/hidden" title="de/XUL/Attribute/hidden">hidden</a> zu verwenden)</p>
<h3 id="Verwandte_Themen" name="Verwandte_Themen">Verwandte Themen</h3>
<dl> <dt>Elemente</dt> <dd><code><a href="/de/docs/Mozilla/Tech/XUL/tabbox" title="tabbox">tabbox</a></code>, <code><a href="/de/docs/Mozilla/Tech/XUL/tabs" title="tabs">tabs</a></code>, <code><a href="/de/docs/Mozilla/Tech/XUL/tabpanels" title="tabpanels">tabpanels</a></code>, <code><a href="/de/docs/Mozilla/Tech/XUL/tabpanel" title="tabpanel">tabpanel</a></code>.</dd> <dt>Schnittstellen</dt> <dd><a href="/de/NsIAccessibleProvider" title="de/NsIAccessibleProvider">nsIAccessibleProvider</a>, <a href="/de/NsIDOMXULSelectControlItemElement" title="de/NsIDOMXULSelectControlItemElement">nsIDOMXULSelectControlItemElement</a></dd>
</dl>
|