Byte-Welt Forum

Zurück   Byte-Welt Forum > Projekte > DockingFrames

DockingFrames DockingFrames An extension of Swing, used to flexibly arrange windows. - Ist eine Erweiterung von Swing, mit der flexibel Panels angeordnet werden können.

Antwort
 
Themen-Optionen Thema durchsuchen
Alt 24.06.2010, 14:13   #1
keresztg starter
 
Registriert seit: 01.07.2009
Beiträge: 6
keresztg befindet sich auf einem aufstrebenden Ast
Standard Empty title of externalized frames

Hi all!

I'm fiddling with externalized windows. I'm using DefaultScreenDockWindowFactory with Kind.FRAME and setting show dock title to true (title text is explicitely nulled on the factory). Undecorated is set to false.
Unfortunately the created JFrames have no title.
Digging the code lead me to AbstractScreenDockWindow.setDockable() as the possible point where the title of the frame should be updated, but that method calls updateTitleIcon() twice but doesn't call updateTitleText().
Changing one updateTitleIcon() to updateTitleText() updates the title of the JFrame correctly. Is it possible that the second updateTitleIcon() call is a copy&paste bug?

By the way the title of the JFrame is correct only while it contains only a single dockable. If it contains more than one dockable in a tabbed window the title of the JFrame becames empty. Is it possible to somehow merge all the titles of the dockables and show it on the JFrame?

Greets,
Gabor
keresztg ist offline   Mit Zitat antworten
Alt 24.06.2010, 18:13   #2
Beni
Moderator
 
Benutzerbild von Beni
 
Registriert seit: 27.08.2006
Beiträge: 571
Beni befindet sich auf einem aufstrebenden Ast
Beni eine Nachricht über Skype™ schicken
Standard Re: Empty title of externalized frames

Yeah, that was a bug... I'll upload a repaired version on the weekend.

As for the second question: the title you (do not) see is the title of the StackDockStation that is created when combining some Dockables. You could create your own window-class. Since that class knows when a Dockable is present (setDockable...) it could add listeners to find out when Dockables are added and removed or when their title changes. It would update its title whenever it receives some event. I can write you some code if you need it.

You can also set a default title-text for all DockStations: use the key "PropertyKey.DOCK_STATION_TITLE" and CControl#putProperty to set the default title.
__________________
Beni ist offline   Mit Zitat antworten
Alt 29.06.2010, 11:48   #3
keresztg starter
 
Registriert seit: 01.07.2009
Beiträge: 6
keresztg befindet sich auf einem aufstrebenden Ast
Standard Re: Empty title of externalized frames

Zitat:
Zitat von Beni Beitrag anzeigen
As for the second question: the title you (do not) see is the title of the StackDockStation that is created when combining some Dockables. You could create your own window-class. Since that class knows when a Dockable is present (setDockable...) it could add listeners to find out when Dockables are added and removed or when their title changes. It would update its title whenever it receives some event. I can write you some code if you need it.
So should I extend eg. ScreenDockFrame in a way that it handles in setDockable(...) the case when a StackDockStation is set? Then which kind of listener should I use? (Eer, sorry, currently I'm lost inside the Eclipse theme... I'll post some fixes to it later. )
keresztg ist offline   Mit Zitat antworten
Alt 29.06.2010, 19:14   #4
Beni
Moderator
 
Benutzerbild von Beni
 
Registriert seit: 27.08.2006
Beiträge: 571
Beni befindet sich auf einem aufstrebenden Ast
Beni eine Nachricht über Skype™ schicken
Standard Re: Empty title of externalized frames

A DockStationListener will inform you when Dockables are added or removed from the station. And a DockableListener will inform you when the title of a Dockable changed (you would have to add this listener to each child of the station).
__________________
Beni ist offline   Mit Zitat antworten
Antwort

Lesezeichen

Stichworte
-


Aktive Benutzer in diesem Thema: 1 (Registrierte Benutzer: 0, Gäste: 1)
 
Themen-Optionen Thema durchsuchen
Thema durchsuchen:

Erweiterte Suche

Forumregeln
Es ist Ihnen erlaubt, neue Themen zu verfassen.
Es ist Ihnen erlaubt, auf Beiträge zu antworten.
Es ist Ihnen nicht erlaubt, Anhänge hochzuladen.
Es ist Ihnen nicht erlaubt, Ihre Beiträge zu bearbeiten.

BB-Code ist an.
Smileys sind an.
[IMG] Code ist an.
HTML-Code ist aus.


Ähnliche Themen
Thema Autor Forum Antworten Letzter Beitrag
Remove empty header of a dockable in a SplitDockstation ley DockingFrames 2 15.04.2010 09:39
Variablenübergabe zwischen 2 gui-frames Unregistriert Java Standard Edition (J2SE) 10 22.03.2010 17:25
new in docking frames sara DockingFrames 7 07.01.2010 20:22
Maximize an externalized dockable Peter DockingFrames 5 05.01.2009 21:41
[Erledigt] empty String bei Formularen swerflash Java Standard Edition (J2SE) 4 04.07.2008 09:28


Alle Zeitangaben in WEZ +1. Es ist jetzt 06:07 Uhr.


Powered by vBulletin® Version 3.8.2 (Deutsch)
Copyright ©2000 - 2010, Jelsoft Enterprises Ltd.