Startseite › Foren › Deutsches LiveCode-Forum › NavBar und Fenstergröße @Jo.Keller › Antwort auf: NavBar und Fenstergröße @Jo.Keller
März 7, 2019 um 13:54 Uhr
#13343
Hallo Joachim,
Du kannst doch jederzeit mit:
...
put the width of this stack into tBreite
...
die aktuelle Breite des Stacks ermitteln.
Diese Info dann einfach zum „skalieren“ Deines NavBars verwenden:
...
put the width of this stack into tBreite
## Nun manipulieren wir das RECT des Navbars:
## the rect of xyz = x1,y1,x2,y2 = links, oben,rechts,unten
put the rect of widget "NavBar" into tRect
## So verändern wir nur die Breite eines Objektes,
## Dein NavBar sitzt ja ganz links, also x1 = 0
## und wir können diesen Trick anwenden:
put tBreite into item 3 of tRect
## Und...
set the rect of widget "NavBar" to tRect
## ... fertig! :-)
...
Gruß
Klaus