broken Roassal2Spec Adapter

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

broken Roassal2Spec Adapter

Peter Uhnak
Hi,

apparently we broke MorphicRoassalAdapter when cleaning Spec, I attached a fix.

However my question is - does anybody (except us) actually use the Roassal2Spec package? Because otherwise we could clean it a bit. For example I'm not sure of the use case of script:/lastEvent:.

Peter

_______________________________________________
Moose-dev mailing list
[hidden email]
https://www.iam.unibe.ch/mailman/listinfo/moose-dev

Roassal2Spec-PeterUhnak.6.mcz (5K) Download Attachment
Reply | Threaded
Open this post in threaded view
|

Re: broken Roassal2Spec Adapter

jfabry

Yes, I use it for LRP.

I instantiate a RoassalModel and then set the script, as below. Sometimes I redraw the entire visualization by sending the refresh message to the RoassalModel instance. I don’t do anything else, really (no idea what event and lastEvent is about). 

treeview := self instantiate: RoassalModel.
treeview script: [:view :canvas | self buildTreeOnView: view ].



On Feb 28, 2015, at 14:05, Peter Uhnák <[hidden email]> wrote:

Hi,

apparently we broke MorphicRoassalAdapter when cleaning Spec, I attached a fix.

However my question is - does anybody (except us) actually use the Roassal2Spec package? Because otherwise we could clean it a bit. For example I'm not sure of the use case of script:/lastEvent:.

Peter
<Roassal2Spec-PeterUhnak.6.mcz>_______________________________________________
Moose-dev mailing list
[hidden email]
https://www.iam.unibe.ch/mailman/listinfo/moose-dev



---> Save our in-boxes! http://emailcharter.org <---

Johan Fabry   -   http://pleiad.cl/~jfabry
PLEIAD lab  -  Computer Science Department (DCC)  -  University of Chile


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

Re: broken Roassal2Spec Adapter

Peter Uhnak
For me it seems weird thet applyScript (refresh) destroys the view and creates it again. Wouldn't it make more sense to expose the view on model and then instead of refresh use cleanAll (RTView>>cleanAll)?

Or maybe we should just make a new Model/Adapter for our needs and leave the Roassal's alone. :)

Peter

On Sat, Feb 28, 2015 at 7:23 PM, Johan Fabry <[hidden email]> wrote:

Yes, I use it for LRP.

I instantiate a RoassalModel and then set the script, as below. Sometimes I redraw the entire visualization by sending the refresh message to the RoassalModel instance. I don’t do anything else, really (no idea what event and lastEvent is about). 

treeview := self instantiate: RoassalModel.
treeview script: [:view :canvas | self buildTreeOnView: view ].



On Feb 28, 2015, at 14:05, Peter Uhnák <[hidden email]> wrote:

Hi,

apparently we broke MorphicRoassalAdapter when cleaning Spec, I attached a fix.

However my question is - does anybody (except us) actually use the Roassal2Spec package? Because otherwise we could clean it a bit. For example I'm not sure of the use case of script:/lastEvent:.

Peter
<Roassal2Spec-PeterUhnak.6.mcz>_______________________________________________
Moose-dev mailing list
[hidden email]
https://www.iam.unibe.ch/mailman/listinfo/moose-dev



---> Save our in-boxes! http://emailcharter.org <---

Johan Fabry   -   http://pleiad.cl/~jfabry
PLEIAD lab  -  Computer Science Department (DCC)  -  University of Chile


_______________________________________________
Moose-dev mailing list
[hidden email]
https://www.iam.unibe.ch/mailman/listinfo/moose-dev



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

Re: broken Roassal2Spec Adapter

jfabry

I don’t know what’s best right now. I think I should sit together with Alex for a bit, so we can talk about it and produce a cleaner version.

I think that for now we can leave it alone, just make sure that it keeps working and you add a bug report so that Alex and I can look at it when we can find some time to sit together.

On Feb 28, 2015, at 15:44, Peter Uhnák <[hidden email]> wrote:

For me it seems weird thet applyScript (refresh) destroys the view and creates it again. Wouldn't it make more sense to expose the view on model and then instead of refresh use cleanAll (RTView>>cleanAll)?

Or maybe we should just make a new Model/Adapter for our needs and leave the Roassal's alone. :)

Peter

On Sat, Feb 28, 2015 at 7:23 PM, Johan Fabry <[hidden email]> wrote:

Yes, I use it for LRP.

I instantiate a RoassalModel and then set the script, as below. Sometimes I redraw the entire visualization by sending the refresh message to the RoassalModel instance. I don’t do anything else, really (no idea what event and lastEvent is about). 

treeview := self instantiate: RoassalModel.
treeview script: [:view :canvas | self buildTreeOnView: view ].



On Feb 28, 2015, at 14:05, Peter Uhnák <[hidden email]> wrote:

Hi,

apparently we broke MorphicRoassalAdapter when cleaning Spec, I attached a fix.

However my question is - does anybody (except us) actually use the Roassal2Spec package? Because otherwise we could clean it a bit. For example I'm not sure of the use case of script:/lastEvent:.

Peter
<Roassal2Spec-PeterUhnak.6.mcz>_______________________________________________
Moose-dev mailing list
[hidden email]
https://www.iam.unibe.ch/mailman/listinfo/moose-dev



---> Save our in-boxes! http://emailcharter.org <---

Johan Fabry   -   http://pleiad.cl/~jfabry
PLEIAD lab  -  Computer Science Department (DCC)  -  University of Chile


_______________________________________________
Moose-dev mailing list
[hidden email]
https://www.iam.unibe.ch/mailman/listinfo/moose-dev


_______________________________________________
Moose-dev mailing list
[hidden email]
https://www.iam.unibe.ch/mailman/listinfo/moose-dev



---> Save our in-boxes! http://emailcharter.org <---

Johan Fabry   -   http://pleiad.cl/~jfabry
PLEIAD lab  -  Computer Science Department (DCC)  -  University of Chile


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

Re: broken Roassal2Spec Adapter

Peter Uhnak
Ok.

The fix I sent in the first mail seems to work also for the refresh.

We can change the model/adapter once the "proper" way is decided for Spec.

Peter

On Sat, Feb 28, 2015 at 9:23 PM, Johan Fabry <[hidden email]> wrote:

I don’t know what’s best right now. I think I should sit together with Alex for a bit, so we can talk about it and produce a cleaner version.

I think that for now we can leave it alone, just make sure that it keeps working and you add a bug report so that Alex and I can look at it when we can find some time to sit together.

On Feb 28, 2015, at 15:44, Peter Uhnák <[hidden email]> wrote:

For me it seems weird thet applyScript (refresh) destroys the view and creates it again. Wouldn't it make more sense to expose the view on model and then instead of refresh use cleanAll (RTView>>cleanAll)?

Or maybe we should just make a new Model/Adapter for our needs and leave the Roassal's alone. :)

Peter

On Sat, Feb 28, 2015 at 7:23 PM, Johan Fabry <[hidden email]> wrote:

Yes, I use it for LRP.

I instantiate a RoassalModel and then set the script, as below. Sometimes I redraw the entire visualization by sending the refresh message to the RoassalModel instance. I don’t do anything else, really (no idea what event and lastEvent is about). 

treeview := self instantiate: RoassalModel.
treeview script: [:view :canvas | self buildTreeOnView: view ].



On Feb 28, 2015, at 14:05, Peter Uhnák <[hidden email]> wrote:

Hi,

apparently we broke MorphicRoassalAdapter when cleaning Spec, I attached a fix.

However my question is - does anybody (except us) actually use the Roassal2Spec package? Because otherwise we could clean it a bit. For example I'm not sure of the use case of script:/lastEvent:.

Peter
<Roassal2Spec-PeterUhnak.6.mcz>_______________________________________________
Moose-dev mailing list
[hidden email]
https://www.iam.unibe.ch/mailman/listinfo/moose-dev



---> Save our in-boxes! http://emailcharter.org <---

Johan Fabry   -   http://pleiad.cl/~jfabry
PLEIAD lab  -  Computer Science Department (DCC)  -  University of Chile


_______________________________________________
Moose-dev mailing list
[hidden email]
https://www.iam.unibe.ch/mailman/listinfo/moose-dev


_______________________________________________
Moose-dev mailing list
[hidden email]
https://www.iam.unibe.ch/mailman/listinfo/moose-dev



---> Save our in-boxes! http://emailcharter.org <---

Johan Fabry   -   http://pleiad.cl/~jfabry
PLEIAD lab  -  Computer Science Department (DCC)  -  University of Chile


_______________________________________________
Moose-dev mailing list
[hidden email]
https://www.iam.unibe.ch/mailman/listinfo/moose-dev



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

Re: broken Roassal2Spec Adapter

Peter H. Meadows
In reply to this post by Peter Uhnak
On 28 February 2015 at 18:44, Peter Uhnák <[hidden email]> wrote:
> For me it seems weird thet applyScript (refresh) destroys the view and
> creates it again. Wouldn't it make more sense to expose the view on model
> and then instead of refresh use cleanAll (RTView>>cleanAll)?
>

How can I use the same RTView? (instead of destroying each time).

> Or maybe we should just make a new Model/Adapter for our needs and leave the
> Roassal's alone. :)
>
> Peter
>
> On Sat, Feb 28, 2015 at 7:23 PM, Johan Fabry <[hidden email]> wrote:
>>
>>
>> Yes, I use it for LRP.
>>
>> I instantiate a RoassalModel and then set the script, as below. Sometimes
>> I redraw the entire visualization by sending the refresh message to the
>> RoassalModel instance. I don’t do anything else, really (no idea what event
>> and lastEvent is about).
>>
>> treeview := self instantiate: RoassalModel.
>> treeview script: [:view :canvas | self buildTreeOnView: view ].
>>
>>
>>
>> On Feb 28, 2015, at 14:05, Peter Uhnák <[hidden email]> wrote:
>>
>> Hi,
>>
>> apparently we broke MorphicRoassalAdapter when cleaning Spec, I attached a
>> fix.
>>
>> However my question is - does anybody (except us) actually use the
>> Roassal2Spec package? Because otherwise we could clean it a bit. For example
>> I'm not sure of the use case of script:/lastEvent:.
>>
>> Peter
>>
>> <Roassal2Spec-PeterUhnak.6.mcz>_______________________________________________
>> Moose-dev mailing list
>> [hidden email]
>> https://www.iam.unibe.ch/mailman/listinfo/moose-dev
>>
>>
>>
>>
>> ---> Save our in-boxes! http://emailcharter.org <---
>>
>> Johan Fabry   -   http://pleiad.cl/~jfabry
>> PLEIAD lab  -  Computer Science Department (DCC)  -  University of Chile
>>
>>
>> _______________________________________________
>> Moose-dev mailing list
>> [hidden email]
>> https://www.iam.unibe.ch/mailman/listinfo/moose-dev
>>
>
>
> _______________________________________________
> Moose-dev mailing list
> [hidden email]
> https://www.iam.unibe.ch/mailman/listinfo/moose-dev
>
_______________________________________________
Moose-dev mailing list
[hidden email]
https://www.list.inf.unibe.ch/listinfo/moose-dev
Reply | Threaded
Open this post in threaded view
|

Re: broken Roassal2Spec Adapter

Peter Uhnak
On 10/16, Peter H. Meadows wrote:
> On 28 February 2015 at 18:44, Peter Uhnák <[hidden email]> wrote:
> > For me it seems weird thet applyScript (refresh) destroys the view and
> > creates it again. Wouldn't it make more sense to expose the view on model
> > and then instead of refresh use cleanAll (RTView>>cleanAll)?
> >
>
> How can I use the same RTView? (instead of destroying each time).


What I've done for my purposes is subclass RoassalModel and extract
the variable.

~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
RoassalModel subclass: #MyRoassalModel
        instanceVariableNames: 'roassalView'
        classVariableNames: ''
        package: 'MyPackage'

MyRoassalModel>>initialize
        super initialize.
        self script: [ :view :canvas |
                roassalView := view
        ]
~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~

It's ugly (extracting vars out of block), but I never got around to
making a proper solution.

>
> > Or maybe we should just make a new Model/Adapter for our needs and leave the
> > Roassal's alone. :)
> >
> > Peter
> >
> > On Sat, Feb 28, 2015 at 7:23 PM, Johan Fabry <[hidden email]> wrote:
> >>
> >>
> >> Yes, I use it for LRP.
> >>
> >> I instantiate a RoassalModel and then set the script, as below. Sometimes
> >> I redraw the entire visualization by sending the refresh message to the
> >> RoassalModel instance. I don’t do anything else, really (no idea what event
> >> and lastEvent is about).
> >>
> >> treeview := self instantiate: RoassalModel.
> >> treeview script: [:view :canvas | self buildTreeOnView: view ].
> >>
> >>
> >>
> >> On Feb 28, 2015, at 14:05, Peter Uhnák <[hidden email]> wrote:
> >>
> >> Hi,
> >>
> >> apparently we broke MorphicRoassalAdapter when cleaning Spec, I attached a
> >> fix.
> >>
> >> However my question is - does anybody (except us) actually use the
> >> Roassal2Spec package? Because otherwise we could clean it a bit. For example
> >> I'm not sure of the use case of script:/lastEvent:.
> >>
> >> Peter
> >>
> >> <Roassal2Spec-PeterUhnak.6.mcz>_______________________________________________
> >> Moose-dev mailing list
> >> [hidden email]
> >> https://www.iam.unibe.ch/mailman/listinfo/moose-dev
> >>
> >>
> >>
> >>
> >> ---> Save our in-boxes! http://emailcharter.org <---
> >>
> >> Johan Fabry   -   http://pleiad.cl/~jfabry
> >> PLEIAD lab  -  Computer Science Department (DCC)  -  University of Chile
> >>
> >>
> >> _______________________________________________
> >> Moose-dev mailing list
> >> [hidden email]
> >> https://www.iam.unibe.ch/mailman/listinfo/moose-dev
> >>
> >
> >
> > _______________________________________________
> > Moose-dev mailing list
> > [hidden email]
> > https://www.iam.unibe.ch/mailman/listinfo/moose-dev
> >
> _______________________________________________
> Moose-dev mailing list
> [hidden email]
> https://www.list.inf.unibe.ch/listinfo/moose-dev

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

Re: broken Roassal2Spec Adapter

abergel
I think this is the only way to do it

Alexandre
-- 
_,.;:~^~:;._,.;:~^~:;._,.;:~^~:;._,.;:~^~:;._,.;:
Alexandre Bergel  http://www.bergel.eu
^~:;._,.;:~^~:;._,.;:~^~:;._,.;:~^~:;._,.;:~^~:;.



On Dec 1, 2015, at 5:50 AM, Peter Uhnak <[hidden email]> wrote:

On 10/16, Peter H. Meadows wrote:
On 28 February 2015 at 18:44, Peter Uhnák <[hidden email]> wrote:
For me it seems weird thet applyScript (refresh) destroys the view and
creates it again. Wouldn't it make more sense to expose the view on model
and then instead of refresh use cleanAll (RTView>>cleanAll)?


How can I use the same RTView? (instead of destroying each time).


What I've done for my purposes is subclass RoassalModel and extract
the variable.

~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
RoassalModel subclass: #MyRoassalModel
instanceVariableNames: 'roassalView'
classVariableNames: ''
package: 'MyPackage'

MyRoassalModel>>initialize
super initialize.
self script: [ :view :canvas |
roassalView := view
]
~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~

It's ugly (extracting vars out of block), but I never got around to
making a proper solution.


Or maybe we should just make a new Model/Adapter for our needs and leave the
Roassal's alone. :)

Peter

On Sat, Feb 28, 2015 at 7:23 PM, Johan Fabry <[hidden email]> wrote:


Yes, I use it for LRP.

I instantiate a RoassalModel and then set the script, as below. Sometimes
I redraw the entire visualization by sending the refresh message to the
RoassalModel instance. I don’t do anything else, really (no idea what event
and lastEvent is about).

treeview := self instantiate: RoassalModel.
treeview script: [:view :canvas | self buildTreeOnView: view ].



On Feb 28, 2015, at 14:05, Peter Uhnák <[hidden email]> wrote:

Hi,

apparently we broke MorphicRoassalAdapter when cleaning Spec, I attached a
fix.

However my question is - does anybody (except us) actually use the
Roassal2Spec package? Because otherwise we could clean it a bit. For example
I'm not sure of the use case of script:/lastEvent:.

Peter

<Roassal2Spec-PeterUhnak.6.mcz>_______________________________________________
Moose-dev mailing list
[hidden email]
https://www.iam.unibe.ch/mailman/listinfo/moose-dev




---> Save our in-boxes! http://emailcharter.org <---

Johan Fabry   -   http://pleiad.cl/~jfabry
PLEIAD lab  -  Computer Science Department (DCC)  -  University of Chile


_______________________________________________
Moose-dev mailing list
[hidden email]
https://www.iam.unibe.ch/mailman/listinfo/moose-dev



_______________________________________________
Moose-dev mailing list
[hidden email]
https://www.iam.unibe.ch/mailman/listinfo/moose-dev

_______________________________________________
Moose-dev mailing list
[hidden email]
https://www.list.inf.unibe.ch/listinfo/moose-dev

--
Peter
_______________________________________________
Moose-dev mailing list
[hidden email]
https://www.list.inf.unibe.ch/listinfo/moose-dev


_______________________________________________
Moose-dev mailing list
[hidden email]
https://www.list.inf.unibe.ch/listinfo/moose-dev