en:gui-usage
Unterschiede
Hier werden die Unterschiede zwischen zwei Versionen angezeigt.
Beide Seiten der vorigen RevisionVorhergehende ÜberarbeitungNächste Überarbeitung | Vorhergehende ÜberarbeitungNächste ÜberarbeitungBeide Seiten der Revision | ||
en:gui-usage [2015/01/01 22:46] – [JMenuBar] roehner | en:gui-usage [2015/01/02 14:07] – [Timer] roehner | ||
---|---|---|---|
Zeile 243: | Zeile 243: | ||
{{: | {{: | ||
- | With a JMenu-component you create a menu for a menu bar. In the object-inspector you specify the desired menu bar at the //MenuBar// attribute, the menu commands (e. g. New, Open, Save, Print, Exit) at the // | + | With a JMenu-component you create a menu for a menu bar. In the object-inspector you specify the desired menu bar at the //MenuBar// attribute, the menu commands (e. g. New, Open, Save, Print, Exit) at the // |
+ | |||
+ | For each menu command the Java-Editor creates a corresponding event method. | ||
\\ | \\ | ||
---- | ---- | ||
- | ==== JTable ==== | ||
- | {{: | ||
- | Set the number of columns and rows with the attributes // | + | ==== JPopupMenu ==== |
+ | {{: | ||
- | With the method // | + | With a JPopupMenu-component |
- | Example: " | + | {{:en: |
- | <code java> | + | In the object inspector you input at the attribute // |
- | int i = jTabelle.getSelectedRow(); | + | |
- | jTabelle.setValueAt(" | + | |
- | </code> | + | |
+ | For each menu command the Java-Editor creates a corresponding event method. | ||
+ | \\ | ||
+ | ---- | ||
==== Timer ==== | ==== Timer ==== | ||
{{: | {{: | ||
Zeile 271: | Zeile 272: | ||
Example: | Example: | ||
- | <code java> timer1.start();</ | + | <code java> |
+ | ... do anything | ||
+ | timer1.stop(); | ||
+ | </ | ||
+ | \\ | ||
+ | ---- | ||
+ | |||
+ | ==== JTable ==== | ||
+ | {{: | ||
+ | |||
+ | Set the number of columns and rows with the attributes // | ||
+ | |||
+ | With the method // | ||
+ | |||
+ | Example: " | ||
+ | |||
+ | <code java> | ||
+ | int i = jTabelle.getSelectedRow(); | ||
+ | jTabelle.setValueAt(" | ||
+ | </ | ||
+ | \\ | ||
+ | ---- | ||
en/gui-usage.txt · Zuletzt geändert: 2022/09/02 10:20 von 127.0.0.1