Polymorph - TabIndex and layoutFrames questions

Previous Topic Next Topic
 
classic Classic list List threaded Threaded
16 messages Options
Reply | Threaded
Open this post in threaded view
|

Polymorph - TabIndex and layoutFrames questions

gerard alis

1- How i can change the #position or #extent of a Morph with a layoutFrame setted ?

for example, i have a button "anchored" to top and right; if i set the #position: of that button the position don´t change. Then i try override the #position: accessor of my button; first set #layoutframe: to nil, later do the set normally of #position:   and later set again the old value of #layoutFrame: , for remain the original anchors. But don´t works. Well, if I execute the code in a WorkSpace, line to line, then works! but don´t if execute all code. I don´t understand :|


2- How works the tab index mechanism in Polymorph?

in some of my Views i have controls with unordered tab order in controls. How i can change the order? I don´t see nothing for start.

3- Exists the possibility of change the position of cursor of a textbox?


Regards, and thanks for the help
Reply | Threaded
Open this post in threaded view
|

Re: Polymorph - TabIndex and layoutFrames questions

Stéphane Ducasse
BTW I was thinking about your work (I still have to play with it).

IN MC UI they build the UI useing spec
look at buildWindow
buildWindow
        | window |
        window := SystemWindow labelled: self label.
        window model: self.
        self widgetSpecs do: [:spec |
                | send fractions offsets |
                send := spec first.
                fractions := spec at: 2 ifAbsent: [#(0 0 1 1)].
                offsets := spec at: 3 ifAbsent: [#(0 0 0 0)].
                window
                        addMorph: (self perform: send first withArguments: send allButFirst)
                        fullFrame:
                                (LayoutFrame
                                        fractions:
                                                ((fractions first)@(fractions second) corner:
                                                        (fractions third)@(fractions fourth))
                                        offsets:
                                                ((offsets first)@(offsets second)  corner:
                                                        (offsets third)@(offsets fourth)))].
        ^ window

buttonSpecs
        ^ #((Invert invert 'Show the reverse set of changes')
                 (Export export 'Export the changes as a change set'))
widgetSpecs
        ^ {
                #((listMorph:selection:menu:keystroke: list selection  
methodListMenu: methodListKey:from:) (0 0 1 0.4) (0 0 0 0)).
                { #(textMorph: annotations). #(0 0.4 1 0.4). { 0. 0. 0. self  
defaultAnnotationPaneHeight. } }.
                { #(textMorph: text). #(0 0.4 1 1). { 0. self  
defaultAnnotationPaneHeight. 0. 0. } }.
                }


this is minimal and not optimal but this is nice to have an array of  
literal to describe a UI

Stef


On Sep 13, 2009, at 10:48 PM, nullPointer wrote:

>
>
> 1- How i can change the #position or #extent of a Morph with a  
> layoutFrame
> setted ?
>
> for example, i have a button "anchored" to top and right; if i set the
> #position: of that button the position don´t change. Then i try  
> override the
> #position: accessor of my button; first set #layoutframe: to nil,  
> later do
> the set normally of #position:   and later set again the old value of
> #layoutFrame: , for remain the original anchors. But don´t works.  
> Well, if I
> execute the code in a WorkSpace, line to line, then works! but don´t  
> if
> execute all code. I don´t understand :|
>
>
> 2- How works the tab index mechanism in Polymorph?
>
> in some of my Views i have controls with unordered tab order in  
> controls.
> How i can change the order? I don´t see nothing for start.
>
> 3- Exists the possibility of change the position of cursor of a  
> textbox?
>
>
> Regards, and thanks for the help
>
> --
> View this message in context: http://n2.nabble.com/Polymorph-TabIndex-and-layoutFrames-questions-tp3638041p3638041.html
> Sent from the Pharo Smalltalk mailing list archive at Nabble.com.
>
> _______________________________________________
> Pharo-project mailing list
> [hidden email]
> http://lists.gforge.inria.fr/cgi-bin/mailman/listinfo/pharo-project


_______________________________________________
Pharo-project mailing list
[hidden email]
http://lists.gforge.inria.fr/cgi-bin/mailman/listinfo/pharo-project
Reply | Threaded
Open this post in threaded view
|

Re: [Pharo-project] Polymorph - TabIndex and layoutFrames questions

gerard alis
I don´t know how do that. Seems very complicated for me.

I did think in each widgets implements a method where return his state. The code will be more readable ( i believe ) and seems more easy of implement ( i believe too )

regards



2009/9/14 Stéphane Ducasse-2 (via Nabble) <[hidden email]>
BTW I was thinking about your work (I still have to play with it).

IN MC UI they build the UI useing spec
look at buildWindow
buildWindow
        | window |
        window := SystemWindow labelled: self label.
        window model: self.
        self widgetSpecs do: [:spec |
                | send fractions offsets |
                send := spec first.
                fractions := spec at: 2 ifAbsent: [#(0 0 1 1)].
                offsets := spec at: 3 ifAbsent: [#(0 0 0 0)].
                window
                        addMorph: (self perform: send first withArguments: send allButFirst)
                        fullFrame:
                                (LayoutFrame
                                        fractions:
                                                ((fractions first)@(fractions second) corner:
                                                        (fractions third)@(fractions fourth))
                                        offsets:
                                                ((offsets first)@(offsets second)  corner:
                                                        (offsets third)@(offsets fourth)))].
        ^ window

buttonSpecs
        ^ #((Invert invert 'Show the reverse set of changes')
                 (Export export 'Export the changes as a change set'))
widgetSpecs
        ^ {
                #((listMorph:selection:menu:keystroke: list selection  
methodListMenu: methodListKey:from:) (0 0 1 0.4) (0 0 0 0)).
                { #(textMorph: annotations). #(0 0.4 1 0.4). { 0. 0. 0. self  
defaultAnnotationPaneHeight. } }.
                { #(textMorph: text). #(0 0.4 1 1). { 0. self  
defaultAnnotationPaneHeight. 0. 0. } }.
                }


this is minimal and not optimal but this is nice to have an array of  
literal to describe a UI

Stef


On Sep 13, 2009, at 10:48 PM, nullPointer wrote:

>
>
> 1- How i can change the #position or #extent of a Morph with a  
> layoutFrame
> setted ?
>
> for example, i have a button "anchored" to top and right; if i set the
> #position: of that button the position don´t change. Then i try  
> override the
> #position: accessor of my button; first set #layoutframe: to nil,  
> later do
> the set normally of #position:   and later set again the old value of
> #layoutFrame: , for remain the original anchors. But don´t works.  
> Well, if I
> execute the code in a WorkSpace, line to line, then works! but don´t  
> if
> execute all code. I don´t understand :|
>
>
> 2- How works the tab index mechanism in Polymorph?
>
> in some of my Views i have controls with unordered tab order in  
> controls.
> How i can change the order? I don´t see nothing for start.
>
> 3- Exists the possibility of change the position of cursor of a  
> textbox?
>
>
> Regards, and thanks for the help
>
> --
> View this message in context: http://n2.nabble.com/Polymorph-TabIndex-and-layoutFrames-questions-tp3638041p3638041.html
> Sent from the Pharo Smalltalk mailing list archive at Nabble.com.
>
> _______________________________________________
> Pharo-project mailing list
> [hidden email]
> http://lists.gforge.inria.fr/cgi-bin/mailman/listinfo/pharo-project


_______________________________________________
Pharo-project mailing list
[hidden email]
http://lists.gforge.inria.fr/cgi-bin/mailman/listinfo/pharo-project



View message @ http://n2.nabble.com/Polymorph-TabIndex-and-layoutFrames-questions-tp3638041p3640028.html
To unsubscribe from Polymorph - TabIndex and layoutFrames questions, click here.


Reply | Threaded
Open this post in threaded view
|

Re: Polymorph - TabIndex and layoutFrames questions

Stéphane Ducasse
I gave you the code in the mail ;)
Nothing more or very little is required more than that.

Stef

On Sep 14, 2009, at 9:38 AM, nullPointer wrote:

> I don´t know how do that. Seems very complicated for me.
>
> I did think in each widgets implements a method where return his  
> state. The code will be more readable ( i believe ) and seems more  
> easy of implement ( i believe too )
>
> regards
>
>
>
> 2009/9/14 Stéphane Ducasse-2 (via Nabble) <[hidden email]>
> BTW I was thinking about your work (I still have to play with it).
>
> IN MC UI they build the UI useing spec
> look at buildWindow
> buildWindow
> Â  Â  Â  Â  | window |
> Â  Â  Â  Â  window := SystemWindow labelled: self label.
> Â  Â  Â  Â  window model: self.
> Â  Â  Â  Â  self widgetSpecs do: [:spec |
> Â  Â  Â  Â  Â  Â  Â  Â  | send fractions offsets |
> Â  Â  Â  Â  Â  Â  Â  Â  send := spec first.
> Â  Â  Â  Â  Â  Â  Â  Â  fractions := spec at: 2 ifAbsent: [#(0 0 1  
> 1)].
> Â  Â  Â  Â  Â  Â  Â  Â  offsets := spec at: 3 ifAbsent: [#(0 0 0 0)].
> Â  Â  Â  Â  Â  Â  Â  Â  window
> Â  Â  Â  Â  Â  Â  Â  Â  Â  Â  Â  Â  addMorph: (self perform: send  
> first withArguments: send allButFirst)
> Â  Â  Â  Â  Â  Â  Â  Â  Â  Â  Â  Â  fullFrame:
> Â  Â  Â  Â  Â  Â  Â  Â  Â  Â  Â  Â  Â  Â  Â  Â  (LayoutFrame
> Â  Â  Â  Â  Â  Â  Â  Â  Â  Â  Â  Â  Â  Â  Â  Â  Â  Â  Â  Â  fractions:
> Â  Â  Â  Â  Â  Â  Â  Â  Â  Â  Â  Â  Â  Â  Â  Â  Â  Â  Â  Â  Â  Â  Â  
> Â  ((fractions first)@(fractions second) corner:
> Â  Â  Â  Â  Â  Â  Â  Â  Â  Â  Â  Â  Â  Â  Â  Â  Â  Â  Â  Â  Â  Â  Â  
> Â  Â  Â  Â  Â  (fractions third)@(fractions fourth))
> Â  Â  Â  Â  Â  Â  Â  Â  Â  Â  Â  Â  Â  Â  Â  Â  Â  Â  Â  Â  offsets:
> Â  Â  Â  Â  Â  Â  Â  Â  Â  Â  Â  Â  Â  Â  Â  Â  Â  Â  Â  Â  Â  Â  Â  
> Â  ((offsets first)@(offsets second) Â corner:
> Â  Â  Â  Â  Â  Â  Â  Â  Â  Â  Â  Â  Â  Â  Â  Â  Â  Â  Â  Â  Â  Â  Â  
> Â  Â  Â  Â  Â  (offsets third)@(offsets fourth)))].
> Â  Â  Â  Â  ^ window
>
> buttonSpecs
> Â  Â  Â  Â  ^ #((Invert invert 'Show the reverse set of changes')
> Â  Â  Â  Â  Â  Â  Â  Â  Â (Export export 'Export the changes as a  
> change set'))
> widgetSpecs
> Â  Â  Â  Â  ^ {
> Â  Â  Â  Â  Â  Â  Â  Â  #((listMorph:selection:menu:keystroke: list  
> selection Â
> methodListMenu: methodListKey:from:) (0 0 1 0.4) (0 0 0 0)).
> Â  Â  Â  Â  Â  Â  Â  Â  { #(textMorph: annotations). #(0 0.4 1 0.4).  
> { 0. 0. 0. self Â
> defaultAnnotationPaneHeight. } }.
> Â  Â  Â  Â  Â  Â  Â  Â  { #(textMorph: text). #(0 0.4 1 1). { 0.  
> self Â
> defaultAnnotationPaneHeight. 0. 0. } }.
> Â  Â  Â  Â  Â  Â  Â  Â  }
>
>
> this is minimal and not optimal but this is nice to have an array of Â
> literal to describe a UI
>
> Stef
>
>
> On Sep 13, 2009, at 10:48 PM, nullPointer wrote:
>
> >
> >
> > 1- How i can change the #position or #extent of a Morph with a Â
> > layoutFrame
> > setted ?
> >
> > for example, i have a button "anchored" to top and right; if i set  
> the
> > #position: of that button the position don´t change. Then i try Â
> > override the
> > #position: accessor of my button; first set #layoutframe: to nil, Â
> > later do
> > the set normally of #position: Â  and later set again the old  
> value of
> > #layoutFrame: , for remain the original anchors. But don´t works. Â
> > Well, if I
> > execute the code in a WorkSpace, line to line, then works! but donÂ
> ´t Â
> > if
> > execute all code. I don´t understand :|
> >
> >
> > 2- How works the tab index mechanism in Polymorph?
> >
> > in some of my Views i have controls with unordered tab order in Â
> > controls.
> > How i can change the order? I don´t see nothing for start.
> >
> > 3- Exists the possibility of change the position of cursor of a Â
> > textbox?
> >
> >
> > Regards, and thanks for the help
> >
> > --
> > View this message in context: http://n2.nabble.com/Polymorph-TabIndex-and-layoutFrames-questions-tp3638041p3638041.html
> > Sent from the Pharo Smalltalk mailing list archive at Nabble.com.
> >
> > _______________________________________________
> > Pharo-project mailing list
> > [hidden email]
> > http://lists.gforge.inria.fr/cgi-bin/mailman/listinfo/pharo-project
>
>
> _______________________________________________
> Pharo-project mailing list
> [hidden email]
> http://lists.gforge.inria.fr/cgi-bin/mailman/listinfo/pharo-project
>
>
> View this message in context: Re: [Pharo-project] Polymorph -  
> TabIndex and layoutFrames questions
> Sent from the Pharo Smalltalk mailing list archive at Nabble.com.
> _______________________________________________
> Pharo-project mailing list
> [hidden email]
> http://lists.gforge.inria.fr/cgi-bin/mailman/listinfo/pharo-project


_______________________________________________
Pharo-project mailing list
[hidden email]
http://lists.gforge.inria.fr/cgi-bin/mailman/listinfo/pharo-project
Reply | Threaded
Open this post in threaded view
|

Re: Polymorph - TabIndex and layoutFrames questions

Gary Chambers-4
In reply to this post by gerard alis
1. position/extent depends on how thae morph is laid out in its owner.
LayoutFrame is used when the owner specified a proportional layout, use the
fractions to pin corners and the offsets to.. offset.
If the owner specifies no layout then postion/extent work as expected.
For table layouts things are more complicated (see hResizing/vResizing etc.)

2. Tab order (keyboard navigation) follows the order of the submorphs at
present. Add your morphs (using addMorphback: or via the Polymorph
row/column type stuff) in the order you want navigation to follow.

Regards, Gary

----- Original Message -----
From: "nullPointer" <[hidden email]>
To: <[hidden email]>
Sent: Sunday, September 13, 2009 9:48 PM
Subject: [Pharo-project] Polymorph - TabIndex and layoutFrames questions


>
>
> 1- How i can change the #position or #extent of a Morph with a layoutFrame
> setted ?
>
> for example, i have a button "anchored" to top and right; if i set the
> #position: of that button the position don´t change. Then i try override
> the
> #position: accessor of my button; first set #layoutframe: to nil, later do
> the set normally of #position:   and later set again the old value of
> #layoutFrame: , for remain the original anchors. But don´t works. Well, if
> I
> execute the code in a WorkSpace, line to line, then works! but don´t if
> execute all code. I don´t understand :|
>
>
> 2- How works the tab index mechanism in Polymorph?
>
> in some of my Views i have controls with unordered tab order in controls.
> How i can change the order? I don´t see nothing for start.
>
> 3- Exists the possibility of change the position of cursor of a textbox?
>
>
> Regards, and thanks for the help
>
> --
> View this message in context:
> http://n2.nabble.com/Polymorph-TabIndex-and-layoutFrames-questions-tp3638041p3638041.html
> Sent from the Pharo Smalltalk mailing list archive at Nabble.com.
>
> _______________________________________________
> Pharo-project mailing list
> [hidden email]
> http://lists.gforge.inria.fr/cgi-bin/mailman/listinfo/pharo-project 


_______________________________________________
Pharo-project mailing list
[hidden email]
http://lists.gforge.inria.fr/cgi-bin/mailman/listinfo/pharo-project
Reply | Threaded
Open this post in threaded view
|

Re: [Pharo-project] Polymorph - TabIndex and layoutFrames questions

gerard alis
1. I have always work with owners in ProportionalLayout, don´t let work with another layoutPolicy in the canvas designer. In view designer exists the possibility of "anchor" a widget to top, left, down and right. That is all need the user ( for the moment ) for anchor a widget, but fails to change size and position.Exists the possibility of do it in ProportionalLayout on owner?


2. Then i understand than changing the order of submorphs that works? I will probe.

Regards and many thanks.


2009/9/14 Gary Chambers (via Nabble) <[hidden email]>
1. position/extent depends on how thae morph is laid out in its owner.
LayoutFrame is used when the owner specified a proportional layout, use the
fractions to pin corners and the offsets to.. offset.
If the owner specifies no layout then postion/extent work as expected.
For table layouts things are more complicated (see hResizing/vResizing etc.)

2. Tab order (keyboard navigation) follows the order of the submorphs at
present. Add your morphs (using addMorphback: or via the Polymorph
row/column type stuff) in the order you want navigation to follow.

Regards, Gary

----- Original Message -----
From: "nullPointer" <[hidden email]>
To: <[hidden email]>
Sent: Sunday, September 13, 2009 9:48 PM
Subject: [Pharo-project] Polymorph - TabIndex and layoutFrames questions


>
>
> 1- How i can change the #position or #extent of a Morph with a layoutFrame
> setted ?
>
> for example, i have a button "anchored" to top and right; if i set the
> #position: of that button the position don´t change. Then i try override
> the
> #position: accessor of my button; first set #layoutframe: to nil, later do
> the set normally of #position:   and later set again the old value of
> #layoutFrame: , for remain the original anchors. But don´t works. Well, if
> I
> execute the code in a WorkSpace, line to line, then works! but don´t if
> execute all code. I don´t understand :|
>
>
> 2- How works the tab index mechanism in Polymorph?
>
> in some of my Views i have controls with unordered tab order in controls.
> How i can change the order? I don´t see nothing for start.
>
> 3- Exists the possibility of change the position of cursor of a textbox?
>
>
> Regards, and thanks for the help
>
> --
> View this message in context:
> http://n2.nabble.com/Polymorph-TabIndex-and-layoutFrames-questions-tp3638041p3638041.html
> Sent from the Pharo Smalltalk mailing list archive at Nabble.com.
>
> _______________________________________________
> Pharo-project mailing list
> [hidden email]
> http://lists.gforge.inria.fr/cgi-bin/mailman/listinfo/pharo-project 


_______________________________________________
Pharo-project mailing list
[hidden email]
http://lists.gforge.inria.fr/cgi-bin/mailman/listinfo/pharo-project


View message @ http://n2.nabble.com/Polymorph-TabIndex-and-layoutFrames-questions-tp3638041p3641268.html
To unsubscribe from Polymorph - TabIndex and layoutFrames questions, click here.


Reply | Threaded
Open this post in threaded view
|

Re: Polymorph - TabIndex and layoutFrames questions

Gary Chambers-4

1. "Fixed" positioning can be achived by setting the fractions to [hidden email] for top-left and bottom-right then using the offsets.

Regards, Gary
----- Original Message -----
Sent: Monday, September 14, 2009 12:03 PM
Subject: Re: [Pharo-project] Polymorph - TabIndex and layoutFrames questions

1. I have always work with owners in ProportionalLayout, don´t let work with another layoutPolicy in the canvas designer. In view designer exists the possibility of "anchor" a widget to top, left, down and right. That is all need the user ( for the moment ) for anchor a widget, but fails to change size and position.Exists the possibility of do it in ProportionalLayout on owner?


2. Then i understand than changing the order of submorphs that works? I will probe.

Regards and many thanks.


2009/9/14 Gary Chambers (via Nabble) <[hidden email]>
1. position/extent depends on how thae morph is laid out in its owner.
LayoutFrame is used when the owner specified a proportional layout, use the
fractions to pin corners and the offsets to.. offset.
If the owner specifies no layout then postion/extent work as expected.
For table layouts things are more complicated (see hResizing/vResizing etc.)

2. Tab order (keyboard navigation) follows the order of the submorphs at
present. Add your morphs (using addMorphback: or via the Polymorph
row/column type stuff) in the order you want navigation to follow.

Regards, Gary

----- Original Message -----
From: "nullPointer" <[hidden email]>
To: <[hidden email]>
Sent: Sunday, September 13, 2009 9:48 PM
Subject: [Pharo-project] Polymorph - TabIndex and layoutFrames questions


>
>
> 1- How i can change the #position or #extent of a Morph with a layoutFrame
> setted ?
>
> for example, i have a button "anchored" to top and right; if i set the
> #position: of that button the position don´t change. Then i try override
> the
> #position: accessor of my button; first set #layoutframe: to nil, later do
> the set normally of #position:   and later set again the old value of
> #layoutFrame: , for remain the original anchors. But don´t works. Well, if
> I
> execute the code in a WorkSpace, line to line, then works! but don´t if
> execute all code. I don´t understand :|
>
>
> 2- How works the tab index mechanism in Polymorph?
>
> in some of my Views i have controls with unordered tab order in controls.
> How i can change the order? I don´t see nothing for start.
>
> 3- Exists the possibility of change the position of cursor of a textbox?
>
>
> Regards, and thanks for the help
>
> --
> View this message in context:
> http://n2.nabble.com/Polymorph-TabIndex-and-layoutFrames-questions-tp3638041p3638041.html
> Sent from the Pharo Smalltalk mailing list archive at Nabble.com.
>
> _______________________________________________
> Pharo-project mailing list
> [hidden email]
> http://lists.gforge.inria.fr/cgi-bin/mailman/listinfo/pharo-project 

_______________________________________________
Pharo-project mailing list
[hidden email]
http://lists.gforge.inria.fr/cgi-bin/mailman/listinfo/pharo-project



View this message in context: Re: [Pharo-project] Polymorph - TabIndex and layoutFrames questions
Sent from the Pharo Smalltalk mailing list archive at Nabble.com.


_______________________________________________
Pharo-project mailing list
[hidden email]
http://lists.gforge.inria.fr/cgi-bin/mailman/listinfo/pharo-project

_______________________________________________
Pharo-project mailing list
[hidden email]
http://lists.gforge.inria.fr/cgi-bin/mailman/listinfo/pharo-project
Reply | Threaded
Open this post in threaded view
|

Re: Polymorph - TabIndex and layoutFrames questions

Henrik Sperre Johansen
In reply to this post by gerard alis
1.
Here's the (I believe) equivalent LayoutFrames settings:
#anchorRight    - rightFraction: 1 rightOffset: -pixelsToRight
#anchorBottom - bottomFraction: 1 bottomOffset: -pixelsToBottom
#anchorLeft      - leftFraction: 0 leftOfffset: pixelsToLeft
#anchorTop      - topFraction: 0 topOffset: pixelsToTop

The problem with having just those four options is they don't work well
with resizing when you have more than one widget (try placing two side
by side and locking left + right)...
In those cases you usually want a fraction somewhere between 0/1 for at
least one of the edges, and adjust those a couple of pixels to make a
constant size border between morphs, like this:
Morph1 - leftFraction: 0 leftOffset: 5 rightFraction: 0.5 rightOffset: -2
Morph2 - leftFraction: 0.5 leftOffset: 2 rightFraction: 1 rightOffset: -5

2. Yes, I believe so. Note, this might also modifiy their rendering
order (I haven't checked though), which could be important if you have
partially overlapping morphs

Cheers,
Henry

nullPointer skrev:

> 1. I have always work with owners in ProportionalLayout, don´t let
> work with another layoutPolicy in the canvas designer. In view
> designer exists the possibility of "anchor" a widget to top, left,
> down and right. That is all need the user ( for the moment ) for
> anchor a widget, but fails to change size and position.Exists the
> possibility of do it in ProportionalLayout on owner?
>
>
> 2. Then i understand than changing the order of submorphs that works?
> I will probe.
>
> Regards and many thanks.
>
>
> 2009/9/14 Gary Chambers (via Nabble) <[hidden email]
> <http://n2.nabble.com/user/SendEmail.jtp?type=node&node=3641368&i=0>>
>
>     1. position/extent depends on how thae morph is laid out in its
>     owner.
>     LayoutFrame is used when the owner specified a proportional
>     layout, use the
>     fractions to pin corners and the offsets to.. offset.
>     If the owner specifies no layout then postion/extent work as
>     expected.
>     For table layouts things are more complicated (see
>     hResizing/vResizing etc.)
>
>     2. Tab order (keyboard navigation) follows the order of the
>     submorphs at
>     present. Add your morphs (using addMorphback: or via the Polymorph
>     row/column type stuff) in the order you want navigation to follow.
>
>     Regards, Gary
>
>     ----- Original Message -----
>     From: "nullPointer" <[hidden email]
>     <http://n2.nabble.com/user/SendEmail.jtp?type=node&node=3641268&i=0>>
>     To: <[hidden email]
>     <http://n2.nabble.com/user/SendEmail.jtp?type=node&node=3641268&i=1>>
>     Sent: Sunday, September 13, 2009 9:48 PM
>     Subject: [Pharo-project] Polymorph - TabIndex and layoutFrames
>     questions
>
>
>     >
>     >
>     > 1- How i can change the #position or #extent of a Morph with a
>     layoutFrame
>     > setted ?
>     >
>     > for example, i have a button "anchored" to top and right; if i
>     set the
>     > #position: of that button the position don´t change. Then i try
>     override
>     > the
>     > #position: accessor of my button; first set #layoutframe: to
>     nil, later do
>     > the set normally of #position:   and later set again the old
>     value of
>     > #layoutFrame: , for remain the original anchors. But don´t
>     works. Well, if
>     > I
>     > execute the code in a WorkSpace, line to line, then works! but
>     don´t if
>     > execute all code. I don´t understand :|
>     >
>     >
>     > 2- How works the tab index mechanism in Polymorph?
>     >
>     > in some of my Views i have controls with unordered tab order in
>     controls.
>     > How i can change the order? I don´t see nothing for start.
>     >
>     > 3- Exists the possibility of change the position of cursor of a
>     textbox?
>     >
>     >
>     > Regards, and thanks for the help
>     >
>     > --
>     > View this message in context:
>     >
>     http://n2.nabble.com/Polymorph-TabIndex-and-layoutFrames-questions-tp3638041p3638041.html
>     > Sent from the Pharo Smalltalk mailing list archive at Nabble.com.
>     >
>     > _______________________________________________
>     > Pharo-project mailing list
>     > [hidden email]
>     <http://n2.nabble.com/user/SendEmail.jtp?type=node&node=3641268&i=2>
>     >
>     http://lists.gforge.inria.fr/cgi-bin/mailman/listinfo/pharo-project 
>
>
>     _______________________________________________
>     Pharo-project mailing list
>     [hidden email]
>     <http://n2.nabble.com/user/SendEmail.jtp?type=node&node=3641268&i=3>
>     http://lists.gforge.inria.fr/cgi-bin/mailman/listinfo/pharo-project
>
>
>
> ------------------------------------------------------------------------
> View this message in context: Re: [Pharo-project] Polymorph - TabIndex
> and layoutFrames questions
> <http://n2.nabble.com/Polymorph-TabIndex-and-layoutFrames-questions-tp3638041p3641368.html>
> Sent from the Pharo Smalltalk mailing list archive
> <http://n2.nabble.com/Pharo-Smalltalk-f2305563.html> at Nabble.com.
> ------------------------------------------------------------------------
>
> _______________________________________________
> Pharo-project mailing list
> [hidden email]
> http://lists.gforge.inria.fr/cgi-bin/mailman/listinfo/pharo-project

_______________________________________________
Pharo-project mailing list
[hidden email]
http://lists.gforge.inria.fr/cgi-bin/mailman/listinfo/pharo-project
Reply | Threaded
Open this post in threaded view
|

Re: Polymorph - TabIndex and layoutFrames questions

gerard alis
In reply to this post by Gary Chambers-4


i´m already using fractions and offsets, through my class CLDecorMorph... http://paste.lisp.org/display/87049 

(Note: in that class properties as #position or #top, #left etc  be relatives to owner)

I´m use the owner always with ProportionalLayout and the "anchors" with the fractions-offsets mechanism. The problem is when I try set the #position: or #extent: accessors. Don´t works.




Gary Chambers wrote
1. "Fixed" positioning can be achived by setting the fractions to 0@0 for top-left and bottom-right then using the offsets.

Regards, Gary

  ----- Original Message -----
  From: nullPointer
  To: pharo-project@lists.gforge.inria.fr
  Sent: Monday, September 14, 2009 12:03 PM
  Subject: Re: [Pharo-project] Polymorph - TabIndex and layoutFrames questions


  1. I have always work with owners in ProportionalLayout, don´t let work with another layoutPolicy in the canvas designer. In view designer exists the possibility of "anchor" a widget to top, left, down and right. That is all need the user ( for the moment ) for anchor a widget, but fails to change size and position.Exists the possibility of do it in ProportionalLayout on owner?


  2. Then i understand than changing the order of submorphs that works? I will probe.

  Regards and many thanks.


  2009/9/14 Gary Chambers (via Nabble) <[hidden email]>

    1. position/extent depends on how thae morph is laid out in its owner.
    LayoutFrame is used when the owner specified a proportional layout, use the
    fractions to pin corners and the offsets to.. offset.
    If the owner specifies no layout then postion/extent work as expected.
    For table layouts things are more complicated (see hResizing/vResizing etc.)

    2. Tab order (keyboard navigation) follows the order of the submorphs at
    present. Add your morphs (using addMorphback: or via the Polymorph
    row/column type stuff) in the order you want navigation to follow.

    Regards, Gary


    ----- Original Message -----
    From: "nullPointer" <[hidden email]>
    To: <[hidden email]>
    Sent: Sunday, September 13, 2009 9:48 PM
    Subject: [Pharo-project] Polymorph - TabIndex and layoutFrames questions



    >
    >
    > 1- How i can change the #position or #extent of a Morph with a layoutFrame
    > setted ?
    >
    > for example, i have a button "anchored" to top and right; if i set the
    > #position: of that button the position don´t change. Then i try override
    > the
    > #position: accessor of my button; first set #layoutframe: to nil, later do
    > the set normally of #position:   and later set again the old value of
    > #layoutFrame: , for remain the original anchors. But don´t works. Well, if
    > I
    > execute the code in a WorkSpace, line to line, then works! but don´t if
    > execute all code. I don´t understand :|
    >
    >
    > 2- How works the tab index mechanism in Polymorph?
    >
    > in some of my Views i have controls with unordered tab order in controls.
    > How i can change the order? I don´t see nothing for start.
    >
    > 3- Exists the possibility of change the position of cursor of a textbox?
    >
    >
    > Regards, and thanks for the help
    >
    > --
    > View this message in context:
    > http://n2.nabble.com/Polymorph-TabIndex-and-layoutFrames-questions-tp3638041p3638041.html
    > Sent from the Pharo Smalltalk mailing list archive at Nabble.com.
    >
    > _______________________________________________
    > Pharo-project mailing list
    > [hidden email]
    > http://lists.gforge.inria.fr/cgi-bin/mailman/listinfo/pharo-project 


    _______________________________________________
    Pharo-project mailing list
    [hidden email]
    http://lists.gforge.inria.fr/cgi-bin/mailman/listinfo/pharo-project 



------------------------------------------------------------------------------
  View this message in context: Re: [Pharo-project] Polymorph - TabIndex and layoutFrames questions
  Sent from the Pharo Smalltalk mailing list archive at Nabble.com.



------------------------------------------------------------------------------


  _______________________________________________
  Pharo-project mailing list
  Pharo-project@lists.gforge.inria.fr
  http://lists.gforge.inria.fr/cgi-bin/mailman/listinfo/pharo-project
_______________________________________________
Pharo-project mailing list
Pharo-project@lists.gforge.inria.fr
http://lists.gforge.inria.fr/cgi-bin/mailman/listinfo/pharo-project
Reply | Threaded
Open this post in threaded view
|

Re: Polymorph - TabIndex and layoutFrames questions

Stéphane Ducasse
since I cannot give you feedback on the morphic internal
I will give you some smalltalk ones


anchorToLeft: toLeft toRight: toRight toTop: toTop toBottom: toBottom

        morph owner notNil
                ifTrue:
                        [| fractionsRectangle offsetsRectangle owner |
                        owner := morph owner.
                        anchoredToLeft := toLeft.
                        anchoredToRight := toRight.
                        anchoredToTop := toTop.
                        anchoredToBottom := toBottom.
                        ((anchoredToLeft not) and: [anchoredToRight not]
                                and:[anchoredToBottom not] and:[anchoredToTop not ])
                                        ifTrue: [owner addMorph: morph  fullFrame: nil.]
                ifFalse:
                        [ fractionsRectangle := self pvtBuildFractionsRectangle.
                        offsetsRectangle := self pvtBuildOffsetsRectangle:  
fractionsRectangle.
                        owner addMorph: morph  fullFrame: (LayoutFrame fractions:  
fractionsRectangle offsets: offsetsRectangle)]].
       
looks more smalltalkish to me
BTW for the
        ((anchoredToLeft not) and: [anchoredToRight not]
                                and:[anchoredToBottom not] and:[anchoredToTop not ])
it may be more efficient to use
        &&



_______________________________________________
Pharo-project mailing list
[hidden email]
http://lists.gforge.inria.fr/cgi-bin/mailman/listinfo/pharo-project
Reply | Threaded
Open this post in threaded view
|

Re: [Pharo-project] Polymorph - TabIndex and layoutFrames questions

gerard alis
Bufff, I hate that "format". Kill me :)

I don´t see the message #&& . I have image Pharo dev 10418 BETA.

&& works as #and:  ? is a lazy comparison?

Regards



2009/9/14 Stéphane Ducasse-2 (via Nabble) <[hidden email]>
since I cannot give you feedback on the morphic internal
I will give you some smalltalk ones


anchorToLeft: toLeft toRight: toRight toTop: toTop toBottom: toBottom

        morph owner notNil
                ifTrue:
                        [| fractionsRectangle offsetsRectangle owner |
                        owner := morph owner.
                        anchoredToLeft := toLeft.
                        anchoredToRight := toRight.
                        anchoredToTop := toTop.
                        anchoredToBottom := toBottom.
                        ((anchoredToLeft not) and: [anchoredToRight not]
                                and:[anchoredToBottom not] and:[anchoredToTop not ])
                                        ifTrue: [owner addMorph: morph  fullFrame: nil.]
                ifFalse:
                        [ fractionsRectangle := self pvtBuildFractionsRectangle.
                        offsetsRectangle := self pvtBuildOffsetsRectangle:  
fractionsRectangle.
                        owner addMorph: morph  fullFrame: (LayoutFrame fractions:  
fractionsRectangle offsets: offsetsRectangle)]].
       
looks more smalltalkish to me
BTW for the
        ((anchoredToLeft not) and: [anchoredToRight not]
                                and:[anchoredToBottom not] and:[anchoredToTop not ])
it may be more efficient to use
        &&



_______________________________________________
Pharo-project mailing list
[hidden email]
http://lists.gforge.inria.fr/cgi-bin/mailman/listinfo/pharo-project



View message @ http://n2.nabble.com/Polymorph-TabIndex-and-layoutFrames-questions-tp3638041p3642989.html
To unsubscribe from Re: Polymorph - TabIndex and layoutFrames questions, click here.


Reply | Threaded
Open this post in threaded view
|

Re: Polymorph - TabIndex and layoutFrames questions

Henrik Sperre Johansen
nullPointer skrev:
> I don´t see the message #&& . I have image Pharo dev 10418 BETA.
>
> && works as #and:  ? is a lazy comparison?
>
> Regards

I think Steph meant &, which does not compare lazily (but these are
boolean values already so not exactly alot of computation overhead, and
no subtle sideeffects...).
Alternatively you could use or: or: or: / | | |, drop the not's, and
switch the ifTrue:ifFalse: blocks.
That way, the "interesting" case comes on top too :).

Personally, I'd also use ifNotNil:, and temps moved to their enclosing
scope in this method, but as you say, preferences differ. :)

Cheers,
Henry

_______________________________________________
Pharo-project mailing list
[hidden email]
http://lists.gforge.inria.fr/cgi-bin/mailman/listinfo/pharo-project
Reply | Threaded
Open this post in threaded view
|

Re: Polymorph - TabIndex and layoutFrames questions

Gary Chambers-4
In reply to this post by gerard alis
#position: and #extent: etc. won't work since the owner is laying out as per
the layout frame.
You'll need to adjust the offsets instead...

Regards, Gary

----- Original Message -----
From: "nullPointer" <[hidden email]>
To: <[hidden email]>
Sent: Monday, September 14, 2009 3:37 PM
Subject: Re: [Pharo-project] Polymorph - TabIndex and layoutFrames questions


>
>
>
> i´m already using fractions and offsets, through my class CLDecorMorph...
> http://paste.lisp.org/display/87049
>
> (Note: in that class properties as #position or #top, #left etc  be
> relatives to owner)
>
> I´m use the owner always with ProportionalLayout and the "anchors" with
> the
> fractions-offsets mechanism. The problem is when I try set the #position:
> or
> #extent: accessors. Don´t works.
>
>
>
>
>
> Gary Chambers wrote:
>>
>> 1. "Fixed" positioning can be achived by setting the fractions to 0@0 for
>> top-left and bottom-right then using the offsets.
>>
>> Regards, Gary
>>
>>   ----- Original Message -----
>>   From: nullPointer
>>   To: [hidden email]
>>   Sent: Monday, September 14, 2009 12:03 PM
>>   Subject: Re: [Pharo-project] Polymorph - TabIndex and layoutFrames
>> questions
>>
>>
>>   1. I have always work with owners in ProportionalLayout, don´t let work
>> with another layoutPolicy in the canvas designer. In view designer exists
>> the possibility of "anchor" a widget to top, left, down and right. That
>> is
>> all need the user ( for the moment ) for anchor a widget, but fails to
>> change size and position.Exists the possibility of do it in
>> ProportionalLayout on owner?
>>
>>
>>   2. Then i understand than changing the order of submorphs that works? I
>> will probe.
>>
>>   Regards and many thanks.
>>
>>
>>   2009/9/14 Gary Chambers (via Nabble) <[hidden email]>
>>
>>     1. position/extent depends on how thae morph is laid out in its
>> owner.
>>     LayoutFrame is used when the owner specified a proportional layout,
>> use the
>>     fractions to pin corners and the offsets to.. offset.
>>     If the owner specifies no layout then postion/extent work as
>> expected.
>>     For table layouts things are more complicated (see
>> hResizing/vResizing
>> etc.)
>>
>>     2. Tab order (keyboard navigation) follows the order of the submorphs
>> at
>>     present. Add your morphs (using addMorphback: or via the Polymorph
>>     row/column type stuff) in the order you want navigation to follow.
>>
>>     Regards, Gary
>>
>>
>>     ----- Original Message -----
>>     From: "nullPointer" <[hidden email]>
>>     To: <[hidden email]>
>>     Sent: Sunday, September 13, 2009 9:48 PM
>>     Subject: [Pharo-project] Polymorph - TabIndex and layoutFrames
>> questions
>>
>>
>>
>>     >
>>     >
>>     > 1- How i can change the #position or #extent of a Morph with a
>> layoutFrame
>>     > setted ?
>>     >
>>     > for example, i have a button "anchored" to top and right; if i set
>> the
>>     > #position: of that button the position don´t change. Then i try
>> override
>>     > the
>>     > #position: accessor of my button; first set #layoutframe: to nil,
>> later do
>>     > the set normally of #position:   and later set again the old value
>> of
>>     > #layoutFrame: , for remain the original anchors. But don´t works.
>> Well, if
>>     > I
>>     > execute the code in a WorkSpace, line to line, then works! but
>> don´t
>> if
>>     > execute all code. I don´t understand :|
>>     >
>>     >
>>     > 2- How works the tab index mechanism in Polymorph?
>>     >
>>     > in some of my Views i have controls with unordered tab order in
>> controls.
>>     > How i can change the order? I don´t see nothing for start.
>>     >
>>     > 3- Exists the possibility of change the position of cursor of a
>> textbox?
>>     >
>>     >
>>     > Regards, and thanks for the help
>>     >
>>     > --
>>     > View this message in context:
>>     >
>> http://n2.nabble.com/Polymorph-TabIndex-and-layoutFrames-questions-tp3638041p3638041.html
>>     > Sent from the Pharo Smalltalk mailing list archive at Nabble.com.
>>     >
>>     > _______________________________________________
>>     > Pharo-project mailing list
>>     > [hidden email]
>>     > http://lists.gforge.inria.fr/cgi-bin/mailman/listinfo/pharo-project
>>
>>
>>     _______________________________________________
>>     Pharo-project mailing list
>>     [hidden email]
>>     http://lists.gforge.inria.fr/cgi-bin/mailman/listinfo/pharo-project
>>
>>
>>
>> ------------------------------------------------------------------------------
>>   View this message in context: Re: [Pharo-project] Polymorph - TabIndex
>> and layoutFrames questions
>>   Sent from the Pharo Smalltalk mailing list archive at Nabble.com.
>>
>>
>>
>> ------------------------------------------------------------------------------
>>
>>
>>   _______________________________________________
>>   Pharo-project mailing list
>>   [hidden email]
>>   http://lists.gforge.inria.fr/cgi-bin/mailman/listinfo/pharo-project
>> _______________________________________________
>> Pharo-project mailing list
>> [hidden email]
>> http://lists.gforge.inria.fr/cgi-bin/mailman/listinfo/pharo-project
>>
>
> --
> View this message in context:
> http://n2.nabble.com/Polymorph-TabIndex-and-layoutFrames-questions-tp3638041p3642822.html
> Sent from the Pharo Smalltalk mailing list archive at Nabble.com.
>
> _______________________________________________
> Pharo-project mailing list
> [hidden email]
> http://lists.gforge.inria.fr/cgi-bin/mailman/listinfo/pharo-project 


_______________________________________________
Pharo-project mailing list
[hidden email]
http://lists.gforge.inria.fr/cgi-bin/mailman/listinfo/pharo-project
Reply | Threaded
Open this post in threaded view
|

Re: Polymorph - TabIndex and layoutFrames questions

gerard alis

I´m surely have a lack of knowledge. Can you orient to me a place where that problem is explained (a web page or resource)?

Very thanks for the help.

Gary Chambers wrote
#position: and #extent: etc. won't work since the owner is laying out as per
the layout frame.
You'll need to adjust the offsets instead...

Regards, Gary

----- Original Message -----
From: "nullPointer" <epicfan@gmail.com>
To: <pharo-project@lists.gforge.inria.fr>
Sent: Monday, September 14, 2009 3:37 PM
Subject: Re: [Pharo-project] Polymorph - TabIndex and layoutFrames questions


>
>
>
> i´m already using fractions and offsets, through my class CLDecorMorph...
> http://paste.lisp.org/display/87049
>
> (Note: in that class properties as #position or #top, #left etc  be
> relatives to owner)
>
> I´m use the owner always with ProportionalLayout and the "anchors" with
> the
> fractions-offsets mechanism. The problem is when I try set the #position:
> or
> #extent: accessors. Don´t works.
>
>
>
>
>
> Gary Chambers wrote:
>>
>> 1. "Fixed" positioning can be achived by setting the fractions to 0@0 for
>> top-left and bottom-right then using the offsets.
>>
>> Regards, Gary
>>
>>   ----- Original Message -----
>>   From: nullPointer
>>   To: pharo-project@lists.gforge.inria.fr
>>   Sent: Monday, September 14, 2009 12:03 PM
>>   Subject: Re: [Pharo-project] Polymorph - TabIndex and layoutFrames
>> questions
>>
>>
>>   1. I have always work with owners in ProportionalLayout, don´t let work
>> with another layoutPolicy in the canvas designer. In view designer exists
>> the possibility of "anchor" a widget to top, left, down and right. That
>> is
>> all need the user ( for the moment ) for anchor a widget, but fails to
>> change size and position.Exists the possibility of do it in
>> ProportionalLayout on owner?
>>
>>
>>   2. Then i understand than changing the order of submorphs that works? I
>> will probe.
>>
>>   Regards and many thanks.
>>
>>
>>   2009/9/14 Gary Chambers (via Nabble) <[hidden email]>
>>
>>     1. position/extent depends on how thae morph is laid out in its
>> owner.
>>     LayoutFrame is used when the owner specified a proportional layout,
>> use the
>>     fractions to pin corners and the offsets to.. offset.
>>     If the owner specifies no layout then postion/extent work as
>> expected.
>>     For table layouts things are more complicated (see
>> hResizing/vResizing
>> etc.)
>>
>>     2. Tab order (keyboard navigation) follows the order of the submorphs
>> at
>>     present. Add your morphs (using addMorphback: or via the Polymorph
>>     row/column type stuff) in the order you want navigation to follow.
>>
>>     Regards, Gary
>>
>>
>>     ----- Original Message -----
>>     From: "nullPointer" <[hidden email]>
>>     To: <[hidden email]>
>>     Sent: Sunday, September 13, 2009 9:48 PM
>>     Subject: [Pharo-project] Polymorph - TabIndex and layoutFrames
>> questions
>>
>>
>>
>>     >
>>     >
>>     > 1- How i can change the #position or #extent of a Morph with a
>> layoutFrame
>>     > setted ?
>>     >
>>     > for example, i have a button "anchored" to top and right; if i set
>> the
>>     > #position: of that button the position don´t change. Then i try
>> override
>>     > the
>>     > #position: accessor of my button; first set #layoutframe: to nil,
>> later do
>>     > the set normally of #position:   and later set again the old value
>> of
>>     > #layoutFrame: , for remain the original anchors. But don´t works.
>> Well, if
>>     > I
>>     > execute the code in a WorkSpace, line to line, then works! but
>> don´t
>> if
>>     > execute all code. I don´t understand :|
>>     >
>>     >
>>     > 2- How works the tab index mechanism in Polymorph?
>>     >
>>     > in some of my Views i have controls with unordered tab order in
>> controls.
>>     > How i can change the order? I don´t see nothing for start.
>>     >
>>     > 3- Exists the possibility of change the position of cursor of a
>> textbox?
>>     >
>>     >
>>     > Regards, and thanks for the help
>>     >
>>     > --
>>     > View this message in context:
>>     >
>> http://n2.nabble.com/Polymorph-TabIndex-and-layoutFrames-questions-tp3638041p3638041.html
>>     > Sent from the Pharo Smalltalk mailing list archive at Nabble.com.
>>     >
>>     > _______________________________________________
>>     > Pharo-project mailing list
>>     > [hidden email]
>>     > http://lists.gforge.inria.fr/cgi-bin/mailman/listinfo/pharo-project
>>
>>
>>     _______________________________________________
>>     Pharo-project mailing list
>>     [hidden email]
>>     http://lists.gforge.inria.fr/cgi-bin/mailman/listinfo/pharo-project
>>
>>
>>
>> ------------------------------------------------------------------------------
>>   View this message in context: Re: [Pharo-project] Polymorph - TabIndex
>> and layoutFrames questions
>>   Sent from the Pharo Smalltalk mailing list archive at Nabble.com.
>>
>>
>>
>> ------------------------------------------------------------------------------
>>
>>
>>   _______________________________________________
>>   Pharo-project mailing list
>>   Pharo-project@lists.gforge.inria.fr
>>   http://lists.gforge.inria.fr/cgi-bin/mailman/listinfo/pharo-project
>> _______________________________________________
>> Pharo-project mailing list
>> Pharo-project@lists.gforge.inria.fr
>> http://lists.gforge.inria.fr/cgi-bin/mailman/listinfo/pharo-project
>>
>
> --
> View this message in context:
> http://n2.nabble.com/Polymorph-TabIndex-and-layoutFrames-questions-tp3638041p3642822.html
> Sent from the Pharo Smalltalk mailing list archive at Nabble.com.
>
> _______________________________________________
> Pharo-project mailing list
> Pharo-project@lists.gforge.inria.fr
> http://lists.gforge.inria.fr/cgi-bin/mailman/listinfo/pharo-project 


_______________________________________________
Pharo-project mailing list
Pharo-project@lists.gforge.inria.fr
http://lists.gforge.inria.fr/cgi-bin/mailman/listinfo/pharo-project
Reply | Threaded
Open this post in threaded view
|

Re: Polymorph - TabIndex and layoutFrames questions

Gary Chambers-4
It is not a problem, as such. Just the wau layouts work.
There used to be a good description on Bob's Super Swiki, though that seems
to have vanished.
Try here http://www.visoracle.com/squeak/faq/morphic_.html instead.

Regards, Gary

----- Original Message -----
From: "nullPointer" <[hidden email]>
To: <[hidden email]>
Sent: Monday, September 14, 2009 10:23 PM
Subject: Re: [Pharo-project] Polymorph - TabIndex and layoutFrames questions


>
>
> I´m surely have a lack of knowledge. Can you orient to me a place where
> that
> problem is explained (a web page or resource)?
>
> Very thanks for the help.
>
>
> Gary Chambers wrote:
>>
>> #position: and #extent: etc. won't work since the owner is laying out as
>> per
>> the layout frame.
>> You'll need to adjust the offsets instead...
>>
>> Regards, Gary
>>
>> ----- Original Message -----
>> From: "nullPointer" <[hidden email]>
>> To: <[hidden email]>
>> Sent: Monday, September 14, 2009 3:37 PM
>> Subject: Re: [Pharo-project] Polymorph - TabIndex and layoutFrames
>> questions
>>
>>
>>>
>>>
>>>
>>> i´m already using fractions and offsets, through my class
>>> CLDecorMorph...
>>> http://paste.lisp.org/display/87049
>>>
>>> (Note: in that class properties as #position or #top, #left etc  be
>>> relatives to owner)
>>>
>>> I´m use the owner always with ProportionalLayout and the "anchors" with
>>> the
>>> fractions-offsets mechanism. The problem is when I try set the
>>> #position:
>>> or
>>> #extent: accessors. Don´t works.
>>>
>>>
>>>
>>>
>>>
>>> Gary Chambers wrote:
>>>>
>>>> 1. "Fixed" positioning can be achived by setting the fractions to 0@0
>>>> for
>>>> top-left and bottom-right then using the offsets.
>>>>
>>>> Regards, Gary
>>>>
>>>>   ----- Original Message -----
>>>>   From: nullPointer
>>>>   To: [hidden email]
>>>>   Sent: Monday, September 14, 2009 12:03 PM
>>>>   Subject: Re: [Pharo-project] Polymorph - TabIndex and layoutFrames
>>>> questions
>>>>
>>>>
>>>>   1. I have always work with owners in ProportionalLayout, don´t let
>>>> work
>>>> with another layoutPolicy in the canvas designer. In view designer
>>>> exists
>>>> the possibility of "anchor" a widget to top, left, down and right. That
>>>> is
>>>> all need the user ( for the moment ) for anchor a widget, but fails to
>>>> change size and position.Exists the possibility of do it in
>>>> ProportionalLayout on owner?
>>>>
>>>>
>>>>   2. Then i understand than changing the order of submorphs that works?
>>>> I
>>>> will probe.
>>>>
>>>>   Regards and many thanks.
>>>>
>>>>
>>>>   2009/9/14 Gary Chambers (via Nabble) <[hidden email]>
>>>>
>>>>     1. position/extent depends on how thae morph is laid out in its
>>>> owner.
>>>>     LayoutFrame is used when the owner specified a proportional layout,
>>>> use the
>>>>     fractions to pin corners and the offsets to.. offset.
>>>>     If the owner specifies no layout then postion/extent work as
>>>> expected.
>>>>     For table layouts things are more complicated (see
>>>> hResizing/vResizing
>>>> etc.)
>>>>
>>>>     2. Tab order (keyboard navigation) follows the order of the
>>>> submorphs
>>>> at
>>>>     present. Add your morphs (using addMorphback: or via the Polymorph
>>>>     row/column type stuff) in the order you want navigation to follow.
>>>>
>>>>     Regards, Gary
>>>>
>>>>
>>>>     ----- Original Message -----
>>>>     From: "nullPointer" <[hidden email]>
>>>>     To: <[hidden email]>
>>>>     Sent: Sunday, September 13, 2009 9:48 PM
>>>>     Subject: [Pharo-project] Polymorph - TabIndex and layoutFrames
>>>> questions
>>>>
>>>>
>>>>
>>>>     >
>>>>     >
>>>>     > 1- How i can change the #position or #extent of a Morph with a
>>>> layoutFrame
>>>>     > setted ?
>>>>     >
>>>>     > for example, i have a button "anchored" to top and right; if i
>>>> set
>>>> the
>>>>     > #position: of that button the position don´t change. Then i try
>>>> override
>>>>     > the
>>>>     > #position: accessor of my button; first set #layoutframe: to nil,
>>>> later do
>>>>     > the set normally of #position:   and later set again the old
>>>> value
>>>> of
>>>>     > #layoutFrame: , for remain the original anchors. But don´t works.
>>>> Well, if
>>>>     > I
>>>>     > execute the code in a WorkSpace, line to line, then works! but
>>>> don´t
>>>> if
>>>>     > execute all code. I don´t understand :|
>>>>     >
>>>>     >
>>>>     > 2- How works the tab index mechanism in Polymorph?
>>>>     >
>>>>     > in some of my Views i have controls with unordered tab order in
>>>> controls.
>>>>     > How i can change the order? I don´t see nothing for start.
>>>>     >
>>>>     > 3- Exists the possibility of change the position of cursor of a
>>>> textbox?
>>>>     >
>>>>     >
>>>>     > Regards, and thanks for the help
>>>>     >
>>>>     > --
>>>>     > View this message in context:
>>>>     >
>>>> http://n2.nabble.com/Polymorph-TabIndex-and-layoutFrames-questions-tp3638041p3638041.html
>>>>     > Sent from the Pharo Smalltalk mailing list archive at Nabble.com.
>>>>     >
>>>>     > _______________________________________________
>>>>     > Pharo-project mailing list
>>>>     > [hidden email]
>>>>     >
>>>> http://lists.gforge.inria.fr/cgi-bin/mailman/listinfo/pharo-project
>>>>
>>>>
>>>>     _______________________________________________
>>>>     Pharo-project mailing list
>>>>     [hidden email]
>>>>     http://lists.gforge.inria.fr/cgi-bin/mailman/listinfo/pharo-project
>>>>
>>>>
>>>>
>>>> ------------------------------------------------------------------------------
>>>>   View this message in context: Re: [Pharo-project] Polymorph -
>>>> TabIndex
>>>> and layoutFrames questions
>>>>   Sent from the Pharo Smalltalk mailing list archive at Nabble.com.
>>>>
>>>>
>>>>
>>>> ------------------------------------------------------------------------------
>>>>
>>>>
>>>>   _______________________________________________
>>>>   Pharo-project mailing list
>>>>   [hidden email]
>>>>   http://lists.gforge.inria.fr/cgi-bin/mailman/listinfo/pharo-project
>>>> _______________________________________________
>>>> Pharo-project mailing list
>>>> [hidden email]
>>>> http://lists.gforge.inria.fr/cgi-bin/mailman/listinfo/pharo-project
>>>>
>>>
>>> --
>>> View this message in context:
>>> http://n2.nabble.com/Polymorph-TabIndex-and-layoutFrames-questions-tp3638041p3642822.html
>>> Sent from the Pharo Smalltalk mailing list archive at Nabble.com.
>>>
>>> _______________________________________________
>>> Pharo-project mailing list
>>> [hidden email]
>>> http://lists.gforge.inria.fr/cgi-bin/mailman/listinfo/pharo-project
>>
>>
>> _______________________________________________
>> Pharo-project mailing list
>> [hidden email]
>> http://lists.gforge.inria.fr/cgi-bin/mailman/listinfo/pharo-project
>>
>
> --
> View this message in context:
> http://n2.nabble.com/Polymorph-TabIndex-and-layoutFrames-questions-tp3638041p3645149.html
> Sent from the Pharo Smalltalk mailing list archive at Nabble.com.
>
> _______________________________________________
> Pharo-project mailing list
> [hidden email]
> http://lists.gforge.inria.fr/cgi-bin/mailman/listinfo/pharo-project 


_______________________________________________
Pharo-project mailing list
[hidden email]
http://lists.gforge.inria.fr/cgi-bin/mailman/listinfo/pharo-project
Reply | Threaded
Open this post in threaded view
|

Re: Polymorph - TabIndex and layoutFrames questions

dcorking
In reply to this post by gerard alis
Gary wrote:

> There used to be a good description on Bob's Super Swiki, though that seems
> to have vanished.

This helped me:
http://wiki.squeak.org/squeak/2141

_______________________________________________
Pharo-project mailing list
[hidden email]
http://lists.gforge.inria.fr/cgi-bin/mailman/listinfo/pharo-project