Re: [Pharo-dev] editing the default window size of glamour inspector

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

Re: [Pharo-dev] editing the default window size of glamour inspector

Nicolai Hess
2014-11-12 15:14 GMT+01:00 Clément Bera <[hidden email]>:
Hello,

I would like for specific objects to change the default window size of the glamour inspector (Basically a bigger window will be opened by default for these objects). This is because I extended my inspectors to provide roassal visualization that are quite large.

How can I do it ?

For example I would like something like that:

MyObject>>#gtInitialWindowExtent
    < gtInitialWindowExtent >
    ^ 800@1000

Clement



I think this is not doable.
You can change the method with the inspector pragma to be called with the context (inspector instance)

gtInspectorItemsIn: composite inContext: aGTInspector
    <gtInspectorPresentationOrder: 30>

instead of

gtInspectorItemsIn: composite
    <gtInspectorPresentationOrder: 30>

this way you have access to the glamour inspector. Unfortunately it does not have any
window extent property.

Maybe we can move the initialExtent property from GLMBrowser up to GLMPresentation?
That way it would be accessible and usable for this aGTInspector argument.



Nicolai




_______________________________________________
Moose-dev mailing list
[hidden email]
https://www.iam.unibe.ch/mailman/listinfo/moose-dev
Reply | Threaded
Open this post in threaded view
|

Re: [Pharo-dev] editing the default window size of glamour inspector

Tudor Girba-2
Hi,

Sorry for not replying earlier. Thanks Nicolai for picking this one up. I missed the initial mail.

The initialExtent does not make sense for presentation, and anyway, you would not want to change an inspector when you are inside a flow. If I understand correctly, Clement would want that when he spawns an inspector window on a new object, to set the window size to something else.

The idea of having a gtInitialWindowExtent is intriguing, but it won't really work. The problem is that an object can have associated presentations in several external packages, so defining the initial extent in one of them might not work for the other ones.

But, I was more thinking of a different mechanism that remembers the size of the inspector every time you change it, and have the next window take that size into account. I am even considering having this size cached by the class of the object (not sure yet if that makes sense). What do you think?

Cheers,
Doru


On Mon, Nov 24, 2014 at 12:57 PM, Nicolai Hess <[hidden email]> wrote:
2014-11-12 15:14 GMT+01:00 Clément Bera <[hidden email]>:
Hello,

I would like for specific objects to change the default window size of the glamour inspector (Basically a bigger window will be opened by default for these objects). This is because I extended my inspectors to provide roassal visualization that are quite large.

How can I do it ?

For example I would like something like that:

MyObject>>#gtInitialWindowExtent
    < gtInitialWindowExtent >
    ^ 800@1000

Clement



I think this is not doable.
You can change the method with the inspector pragma to be called with the context (inspector instance)

gtInspectorItemsIn: composite inContext: aGTInspector
    <gtInspectorPresentationOrder: 30>

instead of

gtInspectorItemsIn: composite
    <gtInspectorPresentationOrder: 30>

this way you have access to the glamour inspector. Unfortunately it does not have any
window extent property.

Maybe we can move the initialExtent property from GLMBrowser up to GLMPresentation?
That way it would be accessible and usable for this aGTInspector argument.



Nicolai






--

"Every thing has its own flow"

_______________________________________________
Moose-dev mailing list
[hidden email]
https://www.iam.unibe.ch/mailman/listinfo/moose-dev
Reply | Threaded
Open this post in threaded view
|

Re: [Pharo-dev] editing the default window size of glamour inspector

Ben Coman
Tudor Girba wrote:

> Hi,
>
> Sorry for not replying earlier. Thanks Nicolai for picking this one up.
> I missed the initial mail.
>
> The initialExtent does not make sense for presentation, and anyway, you
> would not want to change an inspector when you are inside a flow. If I
> understand correctly, Clement would want that when he spawns an
> inspector window on a new object, to set the window size to something else.
>
> The idea of having a gtInitialWindowExtent is intriguing, but it won't
> really work. The problem is that an object can have associated
> presentations in several external packages, so defining the initial
> extent in one of them might not work for the other ones.
>
> But, I was more thinking of a different mechanism that remembers the
> size of the inspector every time you change it, and have the next window
> take that size into account.


 > I am even considering having this size cached by the class of the
 > object (not sure yet if that makes sense).

As I was reading, I was thinking to myself that remembering last size
per class would make a lot of sense.  Could there be a button in
Preferences to save initialExtents to file, so these carry over to new
images?
cheers -ben
_______________________________________________
Moose-dev mailing list
[hidden email]
https://www.iam.unibe.ch/mailman/listinfo/moose-dev