Pharo-users
By thread
pharo-users@lists.pharo.org
By month
Messages by month
- ----- 2026 -----
- August
- July
- June
- May
- April
- March
- February
- January
- ----- 2025 -----
- December
- November
- October
- September
- August
- July
- June
- May
- April
- March
- February
- January
- ----- 2024 -----
- December
- November
- October
- September
- August
- July
- June
- May
- April
- March
- February
- January
- ----- 2023 -----
- December
- November
- October
- September
- August
- July
- June
- May
- April
- March
- February
- January
- ----- 2022 -----
- December
- November
- October
- September
- August
- July
- June
- May
- April
- March
- February
- January
- ----- 2021 -----
- December
- November
- October
- September
- August
- July
- June
- May
- April
- March
- February
- January
- ----- 2020 -----
- December
- November
- October
- September
- August
- July
- June
- May
- April
- March
- February
- January
- ----- 2019 -----
- December
- November
- October
- September
- August
- July
- June
- May
- April
- March
- February
- January
- ----- 2018 -----
- December
- November
- October
- September
- August
- July
- June
- May
- April
- March
- February
- January
- ----- 2017 -----
- December
- November
- October
- September
- August
- July
- June
- May
- April
- March
- February
- January
- ----- 2016 -----
- December
- November
- October
- September
- August
- July
- June
- May
- April
- March
- February
- January
- ----- 2015 -----
- December
- November
- October
- September
- August
- July
- June
- May
- April
- March
- February
- January
- ----- 2014 -----
- December
- November
- October
- September
- August
- July
- June
- May
- April
- March
- February
- January
- ----- 2013 -----
- December
- November
- October
- September
- August
- July
- June
- May
- April
- March
- February
- January
- ----- 2012 -----
- December
- November
- October
- September
- August
- July
- June
- May
- April
- March
- February
- January
- ----- 2011 -----
- December
- November
- October
- September
- August
- July
- June
- May
- April
- March
- February
- January
- ----- 2010 -----
- December
- November
- October
- September
- August
- July
- June
- May
- April
- March
- February
- January
November 2013
- 77 participants
- 802 messages
Re: [Pharo-users] Fwd: Pharo download links are down.
by kilon alios
yeah scheduled maintenance , will be working tomorrow.
On Mon, Nov 11, 2013 at 6:40 PM, Arturo Zambrano
<arturo.zambrano(a)gmail.com>wrote:
>
> Hi All,
> sorry if it 's already reported: everything in
> http://files.pharo.org/platform<http://files.pharo.org/platform/Pharo2.0-linux.zip>
> is returning the following error message.
>
>
> ERRORThe requested URL could not be retrieved
> ------------------------------
>
> The following error was encountered while trying to retrieve the URL:
> http://files.pharo.org/platform/Pharo2.0-linux.zip
>
> *Connection to 128.93.162.72 failed.*
>
> The system returned: *(111) Connection refused*
>
>
>
Nov. 11, 2013
Fwd: Pharo download links are down.
by Arturo Zambrano
Hi All,
sorry if it 's already reported: everything in
http://files.pharo.org/platform<http://files.pharo.org/platform/Pharo2.0-linux.zip>
is returning the following error message.
ERRORThe requested URL could not be retrieved
------------------------------
The following error was encountered while trying to retrieve the URL:
http://files.pharo.org/platform/Pharo2.0-linux.zip
*Connection to 128.93.162.72 failed.*
The system returned: *(111) Connection refused*
Nov. 11, 2013
Re: [Pharo-users] Spec - Grid/Table Layout
by prova email
As i imagined XD
From: benjamin.vanryseghem.pharo(a)gmail.com
Date: Mon, 11 Nov 2013 13:16:12 +0100
To: pharo-users(a)lists.pharo.org
Subject: Re: [Pharo-users] Spec - Grid/Table Layout
Now I get it :)
This is not supported in 2.0 in the sense that the Spec version shipped with Pharo 2.0 has evolved :)
You can try it in Pharo 3.0 :)
Ben
On 11 Nov 2013, at 12:08, prova email <prova213(a)hotmail.it> wrote:I'm doing a TreeModel. As you know, widgetDo is not a message of TreeModel, that's why i was asking you if there something wrong. As i asked you in a old post, column: is not a message of TreeModel, so, where do i have to create that message? The following code means to me that i have to create column: into MorphTreeAdapter, a class that i haven't got into my Pharo 2.0.
MorphTreeAdapter>>#columns: columns: columns self widgetDo: [ :w | w columns: columns. w resizerChanged. w updateList ]PaoloFrom: benjamin.vanryseghem.pharo(a)gmail.com
Date: Mon, 11 Nov 2013 12:03:13 +0100
To: pharo-users(a)lists.pharo.org
Subject: Re: [Pharo-users] Spec - Grid/Table Layout
I am sure that Adapters understands widgetDo:To which objects do you send this message ?
Ben
On 11 Nov 2013, at 11:08, prova email <prova213(a)hotmail.it> wrote:Hi Ben, are you sure that the message "widgetDo:" is the right one? It's not a message that my object looks to understand. Thanks in advance.Paolo
From: Benjamin.VanRyseghem.Pharo(a)gmail.com
Date: Fri, 8 Nov 2013 14:34:18 +0100
To: pharo-users(a)lists.pharo.org
Subject: Re: [Pharo-users] Spec - Grid/Table Layout
It is definitely defined in TreeModel :)
Ben
On 08 Nov 2013, at 14:29, prova email <prova213(a)hotmail.it> wrote:Very very very good Ben, thanks a lot. Last question: you use the "columns:" message, but it's not defined in TreeModel. You defined it hereMorphTreeAdapter>>#columns: columns: columns self widgetDo: [ :w | w columns: columns. w resizerChanged. w updateList ]
in the brand new Class MorphTreeAdapter. What's the difference between define columns: here instead of in the TreeModel class?Great job and thank you!Paolo
From: Benjamin.VanRyseghem.Pharo(a)gmail.com
Date: Fri, 8 Nov 2013 14:15:46 +0100
To: pharo-users(a)lists.pharo.org
Subject: Re: [Pharo-users] Spec - Grid/Table Layout
tree := TreeModel new.tree openWithSpec.
tree columns: (Array with: (MorphTreeColumn new rowMorphGetSelector: [:node | node item first asString asMorph ]; headerButtonLabel: 'Name' font: nil; yourself) with: (MorphTreeColumn new rowMorphGetSelector: [:node | node item second asString asMorph ]; headerButtonLabel: 'Last Name' font: nil; yourself) with: (MorphTreeColumn new rowMorphGetSelector: [:node | node item third asString asMorph ]; headerButtonLabel: 'Age' font: nil; yourself) with: (MorphTreeColumn new rowMorphGetSelector: [:node | node item fourth asString asMorph ]; headerButtonLabel: 'Gender' font: nil; yourself) with: (MorphTreeColumn new rowMorphGetSelector: [:node | (ButtonModel new label: 'Yes we can') buildWithSpec hResizing: #spaceFill]; headerButtonLabel: 'Morph' font: nil; yourself)). tree roots: { {'Benjamin'.'Van Ryseghem'.'26'.'M'}. {'Pamela'.'Anderson'.'Far too much'.'F'}} Ben
On 08 Nov 2013, at 14:05, prova email <prova213(a)hotmail.it> wrote:Yes Ben, too much threads! That's why i'm a little bit confused! That's what i understood: i've got two roads-> use TreeModel as you did with Pamela Anderson or use the simple and nested SpecLayout (SpecLayout composed) as Clement did.If in your TreeModel i can put a RadioButtonModel or a ButtonModel or so on... we got the deal!
Paolo
From: Benjamin.VanRyseghem.Pharo(a)gmail.com
Date: Fri, 8 Nov 2013 13:59:51 +0100
To: pharo-users(a)lists.pharo.org
Subject: Re: [Pharo-users] Spec - Grid/Table Layout
I guess too much threads :)
I answer this in another thread I think :P
the block provided to displayBlock:/rowMorphGetSelector: can return anything understanding asMorph.So you can return any custom morph there :)
I think the following work
tree columns: (Array
with: (TreeColumnModel new displayBlock: [:node | node content first asString ]; headerLabel: 'Name'; yourself)
with: (TreeColumnModel new displayBlock: [:node | node content second asString ]; headerLabel: 'Last Name'; yourself)
with: (TreeColumnModel new displayBlock: [:node | node content third asString ]; headerLabel: 'Age'; yourself)
with: (TreeColumnModel new displayBlock: [:node | node content fourth asString ]; headerLabel: 'Gender'; yourself) with: (TreeColumnModel new displayBlock: [:node | Morph new ]; headerLabel: âMorph'; yourself))
or
tree columns: (Array with: (MorphTreeColumn new rowMorphGetSelector: [:node | node item first asString asMorph ]; headerButtonLabel: 'Name' font: nil; yourself) with: (MorphTreeColumn new rowMorphGetSelector: [:node | node item second asString asMorph ]; headerButtonLabel: 'Last Name' font: nil; yourself) with: (MorphTreeColumn new rowMorphGetSelector: [:node | node item third asString asMorph ]; headerButtonLabel: 'Age' font: nil; yourself) with: (MorphTreeColumn new rowMorphGetSelector: [:node | node item fourth asString asMorph ]; headerButtonLabel: 'Gender' font: nil; yourself) with: (MorphTreeColumn new rowMorphGetSelector: [:node | Morph new ]; headerButtonLabel: 'Morph' font: nil; yourself)).And you get something like
<Screen Shot 2013-11-08 at 13.58.51.png>Ben
On 08 Nov 2013, at 13:45, prova email <prova213(a)hotmail.it> wrote:Yes Clement, i've got your .st file. I saw it in Nested Layout thread. I file in it in Pharo and i see that is not as good as a fashion window is. Maybe Morphic is the right solution but, in that way, we are leaving the idea of Bahman, and the 2nd Spec Tuto is in danger!
However, you asked to Ben the same question that i did: can i put some widgets in these cells or only String?
Thanks again!Paolo
From: bera.clement(a)gmail.com
Date: Fri, 8 Nov 2013 12:51:06 +0100
To: pharo-users(a)lists.pharo.org
Subject: Re: [Pharo-users] Spec - Grid/Table Layout
Ben answered in another thread:
About table, I have an example which will be running soon in Pharo (the changes are waiting to be integrated)
tree := TreeModel new.tree openWithSpec.
tree columns: (Array with: (TreeColumnModel new displayBlock: [:node | node content first asString ]; headerLabel: 'Name'; yourself) with: (TreeColumnModel new displayBlock: [:node | node content second asString ]; headerLabel: 'Last Name'; yourself) with: (TreeColumnModel new displayBlock: [:node | node content third asString ]; headerLabel: 'Age'; yourself) with: (TreeColumnModel new displayBlock: [:node | node content fourth asString ]; headerLabel: 'Gender'; yourself)). tree roots: { {'Benjamin'.'Van Ryseghem'.'26'.'M'}. {'Pamela'.'Anderson'.'Far too much'.'F'}}
Right now, you can get the same by - adding MorphTreeAdapter>>#columns: columns: columns self widgetDo: [ :w | w columns: columns. w resizerChanged. w updateList ]
And then evaluating:
tree := TreeModel new.tree openWithSpec.
tree columns: (Array with: (MorphTreeColumn new rowMorphGetSelector: [:node | node item first asString asMorph ]; headerButtonLabel: 'Name' font: nil; yourself) with: (MorphTreeColumn new rowMorphGetSelector: [:node | node item second asString asMorph ]; headerButtonLabel: 'Last Name' font: nil; yourself) with: (MorphTreeColumn new rowMorphGetSelector: [:node | node item third asString asMorph ]; headerButtonLabel: 'Age' font: nil; yourself) with: (MorphTreeColumn new rowMorphGetSelector: [:node | node item fourth asString asMorph ]; headerButtonLabel: 'Gender' font: nil; yourself)). tree roots: { {'Benjamin'.'Van Ryseghem'.'26'.'M'}. {'Pamela'.'Anderson'.'Far too much'.'F'}}
Ben
Ben, in each cell, can we put something else than a String ? If so, can you add an example in the code above ? Thanks.
I guess doing Ben's solution is the best. I did it with nested layout but it is definitely not as good (see file in attachment, add it in your image then evaluate SpecTable new).
2013/11/8 prova email <prova213(a)hotmail.it>
Hi Clement;
I did the Spec tuto made by Bahman (great tuto). As him, i'd like to put some widgets into it. Is it possible? Maybe with the method "items:"? I don't know if the solution that Ben give to us (use Morphic instead of Spec) is suitable, that's because his UI looks like a list that accept only string. Maybe i'm wrong, can you give us more explanations? Or is it something new for you too?
Thanks for your help!Paolo
From: bera.clement(a)gmail.com
Date: Thu, 7 Nov 2013 10:04:51 +0100
To: Bahman(a)bahmanm.com; pharo-users(a)lists.pharo.org
Subject: Re: [Pharo-users] Spec - Grid/Table Layout
Hello,
Actually I had the same problem, I think the best widget that exists for that right now is MultiColumnListModel.
For example, in the senders window (in attachment), the top panel is a MultiColumnListModel. You can have as many lines and as many columns as you want.
We do not have yet a tableLayout, but we miss it. If you plan to implement it, we will be interested in integrating it into Pharo.
Ben can advise you on how to implement that.
2013/11/7 Bahman Movaqar <Bahman(a)bahmanm.com>
Hi all,
Is there a grid/table layout available in Spec? Something like an HTML
table or Swing's GridLayout? If not, how may I achieve such a
functionality?
I'd appreciate any hints/pointers.
--
Bahman Movaqar (http://BahmanM.com)
ERP Evaluation, Implementation & Deployment Consultant
PGP Key ID: 0x6AB5BD68 (keyserver2.pgp.com)
Nov. 11, 2013
Re: [Pharo-users] Spec - Grid/Table Layout
by Benjamin
Now I get it :)
This is not supported in 2.0 in the sense that the Spec version shipped with Pharo 2.0 has evolved :)
You can try it in Pharo 3.0 :)
Ben
On 11 Nov 2013, at 12:08, prova email <prova213(a)hotmail.it> wrote:
> I'm doing a TreeModel. As you know, widgetDo is not a message of TreeModel, that's why i was asking you if there something wrong. As i asked you in a old post, column: is not a message of TreeModel, so, where do i have to create that message? The following code means to me that i have to create column: into MorphTreeAdapter, a class that i haven't got into my Pharo 2.0.
>
> MorphTreeAdapter>>#columns:
> columns: columns
> self widgetDo: [ :w |
> w columns: columns.
> w resizerChanged.
> w updateList ]
> Paolo
> From: benjamin.vanryseghem.pharo(a)gmail.com
> Date: Mon, 11 Nov 2013 12:03:13 +0100
> To: pharo-users(a)lists.pharo.org
> Subject: Re: [Pharo-users] Spec - Grid/Table Layout
>
> I am sure that Adapters understands widgetDo:
> To which objects do you send this message ?
>
> Ben
>
> On 11 Nov 2013, at 11:08, prova email <prova213(a)hotmail.it> wrote:
>
> Hi Ben,
> are you sure that the message "widgetDo:" is the right one? It's not a message that my object looks to understand.
> Thanks in advance.
> Paolo
>
> From: Benjamin.VanRyseghem.Pharo(a)gmail.com
> Date: Fri, 8 Nov 2013 14:34:18 +0100
> To: pharo-users(a)lists.pharo.org
> Subject: Re: [Pharo-users] Spec - Grid/Table Layout
>
> It is definitely defined in TreeModel :)
>
> Ben
>
> On 08 Nov 2013, at 14:29, prova email <prova213(a)hotmail.it> wrote:
>
> Very very very good Ben, thanks a lot. Last question: you use the "columns:" message, but it's not defined in TreeModel. You defined it here
> MorphTreeAdapter>>#columns:
> columns: columns
> self widgetDo: [ :w |
> w columns: columns.
> w resizerChanged.
> w updateList ]
>
> in the brand new Class MorphTreeAdapter. What's the difference between define columns: here instead of in the TreeModel class?
> Great job and thank you!
> Paolo
>
>
> From: Benjamin.VanRyseghem.Pharo(a)gmail.com
> Date: Fri, 8 Nov 2013 14:15:46 +0100
> To: pharo-users(a)lists.pharo.org
> Subject: Re: [Pharo-users] Spec - Grid/Table Layout
>
> tree := TreeModel new.
> tree openWithSpec.
>
> tree columns: (Array
> with: (MorphTreeColumn new rowMorphGetSelector: [:node | node item first asString asMorph ]; headerButtonLabel: 'Name' font: nil; yourself)
> with: (MorphTreeColumn new rowMorphGetSelector: [:node | node item second asString asMorph ]; headerButtonLabel: 'Last Name' font: nil; yourself)
> with: (MorphTreeColumn new rowMorphGetSelector: [:node | node item third asString asMorph ]; headerButtonLabel: 'Age' font: nil; yourself)
> with: (MorphTreeColumn new rowMorphGetSelector: [:node | node item fourth asString asMorph ]; headerButtonLabel: 'Gender' font: nil; yourself)
> with: (MorphTreeColumn new rowMorphGetSelector: [:node | (ButtonModel new label: 'Yes we can') buildWithSpec hResizing: #spaceFill]; headerButtonLabel: 'Morph' font: nil; yourself)).
>
> tree roots: {
> {'Benjamin'.'Van Ryseghem'.'26'.'M'}.
> {'Pamela'.'Anderson'.'Far too much'.'F'}
> }
>
> Ben
>
> On 08 Nov 2013, at 14:05, prova email <prova213(a)hotmail.it> wrote:
>
> Yes Ben, too much threads! That's why i'm a little bit confused! That's what i understood: i've got two roads-> use TreeModel as you did with Pamela Anderson or use the simple and nested SpecLayout (SpecLayout composed) as Clement did.
> If in your TreeModel i can put a RadioButtonModel or a ButtonModel or so on... we got the deal!
>
> Paolo
>
> From: Benjamin.VanRyseghem.Pharo(a)gmail.com
> Date: Fri, 8 Nov 2013 13:59:51 +0100
> To: pharo-users(a)lists.pharo.org
> Subject: Re: [Pharo-users] Spec - Grid/Table Layout
>
> I guess too much threads :)
>
> I answer this in another thread I think :P
>
> the block provided to displayBlock:/rowMorphGetSelector: can return anything understanding asMorph.
> So you can return any custom morph there :)
>
> I think the following work
>
> tree columns: (Array
> with: (TreeColumnModel new displayBlock: [:node | node content first asString ]; headerLabel: 'Name'; yourself)
> with: (TreeColumnModel new displayBlock: [:node | node content second asString ]; headerLabel: 'Last Name'; yourself)
> with: (TreeColumnModel new displayBlock: [:node | node content third asString ]; headerLabel: 'Age'; yourself)
> with: (TreeColumnModel new displayBlock: [:node | node content fourth asString ]; headerLabel: 'Gender'; yourself)
> with: (TreeColumnModel new displayBlock: [:node | Morph new ]; headerLabel: âMorph'; yourself))
>
> or
>
> tree columns: (Array
> with: (MorphTreeColumn new rowMorphGetSelector: [:node | node item first asString asMorph ]; headerButtonLabel: 'Name' font: nil; yourself)
> with: (MorphTreeColumn new rowMorphGetSelector: [:node | node item second asString asMorph ]; headerButtonLabel: 'Last Name' font: nil; yourself)
> with: (MorphTreeColumn new rowMorphGetSelector: [:node | node item third asString asMorph ]; headerButtonLabel: 'Age' font: nil; yourself)
> with: (MorphTreeColumn new rowMorphGetSelector: [:node | node item fourth asString asMorph ]; headerButtonLabel: 'Gender' font: nil; yourself)
> with: (MorphTreeColumn new rowMorphGetSelector: [:node | Morph new ]; headerButtonLabel: 'Morph' font: nil; yourself)).
>
> And you get something like
>
> <Screen Shot 2013-11-08 at 13.58.51.png>
>
> Ben
>
> On 08 Nov 2013, at 13:45, prova email <prova213(a)hotmail.it> wrote:
>
> Yes Clement, i've got your .st file. I saw it in Nested Layout thread. I file in it in Pharo and i see that is not as good as a fashion window is. Maybe Morphic is the right solution but, in that way, we are leaving the idea of Bahman, and the 2nd Spec Tuto is in danger!
>
> However, you asked to Ben the same question that i did: can i put some widgets in these cells or only String?
>
> Thanks again!
> Paolo
>
> From: bera.clement(a)gmail.com
> Date: Fri, 8 Nov 2013 12:51:06 +0100
> To: pharo-users(a)lists.pharo.org
> Subject: Re: [Pharo-users] Spec - Grid/Table Layout
>
> Ben answered in another thread:
>
> About table, I have an example which will be running soon in Pharo (the changes are waiting to be integrated)
>
> tree := TreeModel new.
> tree openWithSpec.
>
> tree columns: (Array
> with: (TreeColumnModel new displayBlock: [:node | node content first asString ]; headerLabel: 'Name'; yourself)
> with: (TreeColumnModel new displayBlock: [:node | node content second asString ]; headerLabel: 'Last Name'; yourself)
> with: (TreeColumnModel new displayBlock: [:node | node content third asString ]; headerLabel: 'Age'; yourself)
> with: (TreeColumnModel new displayBlock: [:node | node content fourth asString ]; headerLabel: 'Gender'; yourself)).
>
> tree roots: {
> {'Benjamin'.'Van Ryseghem'.'26'.'M'}.
> {'Pamela'.'Anderson'.'Far too much'.'F'}
> }
>
>
> Right now, you can get the same by
> - adding MorphTreeAdapter>>#columns:
> columns: columns
> self widgetDo: [ :w |
> w columns: columns.
> w resizerChanged.
> w updateList ]
>
> And then evaluating:
>
> tree := TreeModel new.
> tree openWithSpec.
>
> tree columns: (Array
> with: (MorphTreeColumn new rowMorphGetSelector: [:node | node item first asString asMorph ]; headerButtonLabel: 'Name' font: nil; yourself)
> with: (MorphTreeColumn new rowMorphGetSelector: [:node | node item second asString asMorph ]; headerButtonLabel: 'Last Name' font: nil; yourself)
> with: (MorphTreeColumn new rowMorphGetSelector: [:node | node item third asString asMorph ]; headerButtonLabel: 'Age' font: nil; yourself)
> with: (MorphTreeColumn new rowMorphGetSelector: [:node | node item fourth asString asMorph ]; headerButtonLabel: 'Gender' font: nil; yourself)).
>
> tree roots: {
> {'Benjamin'.'Van Ryseghem'.'26'.'M'}.
> {'Pamela'.'Anderson'.'Far too much'.'F'}
> }
>
> Ben
>
> Ben, in each cell, can we put something else than a String ? If so, can you add an example in the code above ? Thanks.
>
> I guess doing Ben's solution is the best. I did it with nested layout but it is definitely not as good (see file in attachment, add it in your image then evaluate SpecTable new).
>
>
> 2013/11/8 prova email <prova213(a)hotmail.it>
> Hi Clement;
>
> I did the Spec tuto made by Bahman (great tuto). As him, i'd like to put some widgets into it. Is it possible? Maybe with the method "items:"? I don't know if the solution that Ben give to us (use Morphic instead of Spec) is suitable, that's because his UI looks like a list that accept only string. Maybe i'm wrong, can you give us more explanations? Or is it something new for you too?
>
> Thanks for your help!
> Paolo
>
> From: bera.clement(a)gmail.com
> Date: Thu, 7 Nov 2013 10:04:51 +0100
> To: Bahman(a)bahmanm.com; pharo-users(a)lists.pharo.org
> Subject: Re: [Pharo-users] Spec - Grid/Table Layout
>
>
> Hello,
>
> Actually I had the same problem, I think the best widget that exists for that right now is MultiColumnListModel.
>
> For example, in the senders window (in attachment), the top panel is a MultiColumnListModel. You can have as many lines and as many columns as you want.
>
> We do not have yet a tableLayout, but we miss it. If you plan to implement it, we will be interested in integrating it into Pharo.
>
> Ben can advise you on how to implement that.
>
>
>
>
> 2013/11/7 Bahman Movaqar <Bahman(a)bahmanm.com>
> Hi all,
>
> Is there a grid/table layout available in Spec? Something like an HTML
> table or Swing's GridLayout? If not, how may I achieve such a
> functionality?
>
> I'd appreciate any hints/pointers.
>
> --
> Bahman Movaqar (http://BahmanM.com)
>
> ERP Evaluation, Implementation & Deployment Consultant
> PGP Key ID: 0x6AB5BD68 (keyserver2.pgp.com)
Nov. 11, 2013
Re: [Pharo-users] Spec - Grid/Table Layout
by prova email
I'm doing a TreeModel. As you know, widgetDo is not a message of TreeModel, that's why i was asking you if there something wrong. As i asked you in a old post, column: is not a message of TreeModel, so, where do i have to create that message? The following code means to me that i have to create column: into MorphTreeAdapter, a class that i haven't got into my Pharo 2.0.
MorphTreeAdapter>>#columns: columns: columns self widgetDo: [ :w | w columns: columns. w resizerChanged. w updateList ]PaoloFrom: benjamin.vanryseghem.pharo(a)gmail.com
Date: Mon, 11 Nov 2013 12:03:13 +0100
To: pharo-users(a)lists.pharo.org
Subject: Re: [Pharo-users] Spec - Grid/Table Layout
I am sure that Adapters understands widgetDo:To which objects do you send this message ?
Ben
On 11 Nov 2013, at 11:08, prova email <prova213(a)hotmail.it> wrote:Hi Ben, are you sure that the message "widgetDo:" is the right one? It's not a message that my object looks to understand. Thanks in advance.Paolo
From: Benjamin.VanRyseghem.Pharo(a)gmail.com
Date: Fri, 8 Nov 2013 14:34:18 +0100
To: pharo-users(a)lists.pharo.org
Subject: Re: [Pharo-users] Spec - Grid/Table Layout
It is definitely defined in TreeModel :)
Ben
On 08 Nov 2013, at 14:29, prova email <prova213(a)hotmail.it> wrote:Very very very good Ben, thanks a lot. Last question: you use the "columns:" message, but it's not defined in TreeModel. You defined it hereMorphTreeAdapter>>#columns: columns: columns self widgetDo: [ :w | w columns: columns. w resizerChanged. w updateList ]
in the brand new Class MorphTreeAdapter. What's the difference between define columns: here instead of in the TreeModel class?Great job and thank you!Paolo
From: Benjamin.VanRyseghem.Pharo(a)gmail.com
Date: Fri, 8 Nov 2013 14:15:46 +0100
To: pharo-users(a)lists.pharo.org
Subject: Re: [Pharo-users] Spec - Grid/Table Layout
tree := TreeModel new.tree openWithSpec.
tree columns: (Array with: (MorphTreeColumn new rowMorphGetSelector: [:node | node item first asString asMorph ]; headerButtonLabel: 'Name' font: nil; yourself) with: (MorphTreeColumn new rowMorphGetSelector: [:node | node item second asString asMorph ]; headerButtonLabel: 'Last Name' font: nil; yourself) with: (MorphTreeColumn new rowMorphGetSelector: [:node | node item third asString asMorph ]; headerButtonLabel: 'Age' font: nil; yourself) with: (MorphTreeColumn new rowMorphGetSelector: [:node | node item fourth asString asMorph ]; headerButtonLabel: 'Gender' font: nil; yourself) with: (MorphTreeColumn new rowMorphGetSelector: [:node | (ButtonModel new label: 'Yes we can') buildWithSpec hResizing: #spaceFill]; headerButtonLabel: 'Morph' font: nil; yourself)). tree roots: { {'Benjamin'.'Van Ryseghem'.'26'.'M'}. {'Pamela'.'Anderson'.'Far too much'.'F'}} Ben
On 08 Nov 2013, at 14:05, prova email <prova213(a)hotmail.it> wrote:Yes Ben, too much threads! That's why i'm a little bit confused! That's what i understood: i've got two roads-> use TreeModel as you did with Pamela Anderson or use the simple and nested SpecLayout (SpecLayout composed) as Clement did.If in your TreeModel i can put a RadioButtonModel or a ButtonModel or so on... we got the deal!
Paolo
From: Benjamin.VanRyseghem.Pharo(a)gmail.com
Date: Fri, 8 Nov 2013 13:59:51 +0100
To: pharo-users(a)lists.pharo.org
Subject: Re: [Pharo-users] Spec - Grid/Table Layout
I guess too much threads :)
I answer this in another thread I think :P
the block provided to displayBlock:/rowMorphGetSelector: can return anything understanding asMorph.So you can return any custom morph there :)
I think the following work
tree columns: (Array
with: (TreeColumnModel new displayBlock: [:node | node content first asString ]; headerLabel: 'Name'; yourself)
with: (TreeColumnModel new displayBlock: [:node | node content second asString ]; headerLabel: 'Last Name'; yourself)
with: (TreeColumnModel new displayBlock: [:node | node content third asString ]; headerLabel: 'Age'; yourself)
with: (TreeColumnModel new displayBlock: [:node | node content fourth asString ]; headerLabel: 'Gender'; yourself) with: (TreeColumnModel new displayBlock: [:node | Morph new ]; headerLabel: âMorph'; yourself))
or
tree columns: (Array with: (MorphTreeColumn new rowMorphGetSelector: [:node | node item first asString asMorph ]; headerButtonLabel: 'Name' font: nil; yourself) with: (MorphTreeColumn new rowMorphGetSelector: [:node | node item second asString asMorph ]; headerButtonLabel: 'Last Name' font: nil; yourself) with: (MorphTreeColumn new rowMorphGetSelector: [:node | node item third asString asMorph ]; headerButtonLabel: 'Age' font: nil; yourself) with: (MorphTreeColumn new rowMorphGetSelector: [:node | node item fourth asString asMorph ]; headerButtonLabel: 'Gender' font: nil; yourself) with: (MorphTreeColumn new rowMorphGetSelector: [:node | Morph new ]; headerButtonLabel: 'Morph' font: nil; yourself)).And you get something like
<Screen Shot 2013-11-08 at 13.58.51.png>Ben
On 08 Nov 2013, at 13:45, prova email <prova213(a)hotmail.it> wrote:Yes Clement, i've got your .st file. I saw it in Nested Layout thread. I file in it in Pharo and i see that is not as good as a fashion window is. Maybe Morphic is the right solution but, in that way, we are leaving the idea of Bahman, and the 2nd Spec Tuto is in danger!
However, you asked to Ben the same question that i did: can i put some widgets in these cells or only String?
Thanks again!Paolo
From: bera.clement(a)gmail.com
Date: Fri, 8 Nov 2013 12:51:06 +0100
To: pharo-users(a)lists.pharo.org
Subject: Re: [Pharo-users] Spec - Grid/Table Layout
Ben answered in another thread:
About table, I have an example which will be running soon in Pharo (the changes are waiting to be integrated)
tree := TreeModel new.tree openWithSpec.
tree columns: (Array with: (TreeColumnModel new displayBlock: [:node | node content first asString ]; headerLabel: 'Name'; yourself) with: (TreeColumnModel new displayBlock: [:node | node content second asString ]; headerLabel: 'Last Name'; yourself) with: (TreeColumnModel new displayBlock: [:node | node content third asString ]; headerLabel: 'Age'; yourself) with: (TreeColumnModel new displayBlock: [:node | node content fourth asString ]; headerLabel: 'Gender'; yourself)). tree roots: { {'Benjamin'.'Van Ryseghem'.'26'.'M'}. {'Pamela'.'Anderson'.'Far too much'.'F'}}
Right now, you can get the same by - adding MorphTreeAdapter>>#columns: columns: columns self widgetDo: [ :w | w columns: columns. w resizerChanged. w updateList ]
And then evaluating:
tree := TreeModel new.tree openWithSpec.
tree columns: (Array with: (MorphTreeColumn new rowMorphGetSelector: [:node | node item first asString asMorph ]; headerButtonLabel: 'Name' font: nil; yourself) with: (MorphTreeColumn new rowMorphGetSelector: [:node | node item second asString asMorph ]; headerButtonLabel: 'Last Name' font: nil; yourself) with: (MorphTreeColumn new rowMorphGetSelector: [:node | node item third asString asMorph ]; headerButtonLabel: 'Age' font: nil; yourself) with: (MorphTreeColumn new rowMorphGetSelector: [:node | node item fourth asString asMorph ]; headerButtonLabel: 'Gender' font: nil; yourself)). tree roots: { {'Benjamin'.'Van Ryseghem'.'26'.'M'}. {'Pamela'.'Anderson'.'Far too much'.'F'}}
Ben
Ben, in each cell, can we put something else than a String ? If so, can you add an example in the code above ? Thanks.
I guess doing Ben's solution is the best. I did it with nested layout but it is definitely not as good (see file in attachment, add it in your image then evaluate SpecTable new).
2013/11/8 prova email <prova213(a)hotmail.it>
Hi Clement;
I did the Spec tuto made by Bahman (great tuto). As him, i'd like to put some widgets into it. Is it possible? Maybe with the method "items:"? I don't know if the solution that Ben give to us (use Morphic instead of Spec) is suitable, that's because his UI looks like a list that accept only string. Maybe i'm wrong, can you give us more explanations? Or is it something new for you too?
Thanks for your help!Paolo
From: bera.clement(a)gmail.com
Date: Thu, 7 Nov 2013 10:04:51 +0100
To: Bahman(a)bahmanm.com; pharo-users(a)lists.pharo.org
Subject: Re: [Pharo-users] Spec - Grid/Table Layout
Hello,
Actually I had the same problem, I think the best widget that exists for that right now is MultiColumnListModel.
For example, in the senders window (in attachment), the top panel is a MultiColumnListModel. You can have as many lines and as many columns as you want.
We do not have yet a tableLayout, but we miss it. If you plan to implement it, we will be interested in integrating it into Pharo.
Ben can advise you on how to implement that.
2013/11/7 Bahman Movaqar <Bahman(a)bahmanm.com>
Hi all,
Is there a grid/table layout available in Spec? Something like an HTML
table or Swing's GridLayout? If not, how may I achieve such a
functionality?
I'd appreciate any hints/pointers.
--
Bahman Movaqar (http://BahmanM.com)
ERP Evaluation, Implementation & Deployment Consultant
PGP Key ID: 0x6AB5BD68 (keyserver2.pgp.com)
Nov. 11, 2013
Re: [Pharo-users] Spec - Grid/Table Layout
by Benjamin
I am sure that Adapters understands widgetDo:
To which objects do you send this message ?
Ben
On 11 Nov 2013, at 11:08, prova email <prova213(a)hotmail.it> wrote:
> Hi Ben,
> are you sure that the message "widgetDo:" is the right one? It's not a message that my object looks to understand.
> Thanks in advance.
> Paolo
>
> From: Benjamin.VanRyseghem.Pharo(a)gmail.com
> Date: Fri, 8 Nov 2013 14:34:18 +0100
> To: pharo-users(a)lists.pharo.org
> Subject: Re: [Pharo-users] Spec - Grid/Table Layout
>
> It is definitely defined in TreeModel :)
>
> Ben
>
> On 08 Nov 2013, at 14:29, prova email <prova213(a)hotmail.it> wrote:
>
> Very very very good Ben, thanks a lot. Last question: you use the "columns:" message, but it's not defined in TreeModel. You defined it here
> MorphTreeAdapter>>#columns:
> columns: columns
> self widgetDo: [ :w |
> w columns: columns.
> w resizerChanged.
> w updateList ]
>
> in the brand new Class MorphTreeAdapter. What's the difference between define columns: here instead of in the TreeModel class?
> Great job and thank you!
> Paolo
>
>
> From: Benjamin.VanRyseghem.Pharo(a)gmail.com
> Date: Fri, 8 Nov 2013 14:15:46 +0100
> To: pharo-users(a)lists.pharo.org
> Subject: Re: [Pharo-users] Spec - Grid/Table Layout
>
> tree := TreeModel new.
> tree openWithSpec.
>
> tree columns: (Array
> with: (MorphTreeColumn new rowMorphGetSelector: [:node | node item first asString asMorph ]; headerButtonLabel: 'Name' font: nil; yourself)
> with: (MorphTreeColumn new rowMorphGetSelector: [:node | node item second asString asMorph ]; headerButtonLabel: 'Last Name' font: nil; yourself)
> with: (MorphTreeColumn new rowMorphGetSelector: [:node | node item third asString asMorph ]; headerButtonLabel: 'Age' font: nil; yourself)
> with: (MorphTreeColumn new rowMorphGetSelector: [:node | node item fourth asString asMorph ]; headerButtonLabel: 'Gender' font: nil; yourself)
> with: (MorphTreeColumn new rowMorphGetSelector: [:node | (ButtonModel new label: 'Yes we can') buildWithSpec hResizing: #spaceFill]; headerButtonLabel: 'Morph' font: nil; yourself)).
>
> tree roots: {
> {'Benjamin'.'Van Ryseghem'.'26'.'M'}.
> {'Pamela'.'Anderson'.'Far too much'.'F'}
> }
>
> Ben
>
> On 08 Nov 2013, at 14:05, prova email <prova213(a)hotmail.it> wrote:
>
> Yes Ben, too much threads! That's why i'm a little bit confused! That's what i understood: i've got two roads-> use TreeModel as you did with Pamela Anderson or use the simple and nested SpecLayout (SpecLayout composed) as Clement did.
> If in your TreeModel i can put a RadioButtonModel or a ButtonModel or so on... we got the deal!
>
> Paolo
>
> From: Benjamin.VanRyseghem.Pharo(a)gmail.com
> Date: Fri, 8 Nov 2013 13:59:51 +0100
> To: pharo-users(a)lists.pharo.org
> Subject: Re: [Pharo-users] Spec - Grid/Table Layout
>
> I guess too much threads :)
>
> I answer this in another thread I think :P
>
> the block provided to displayBlock:/rowMorphGetSelector: can return anything understanding asMorph.
> So you can return any custom morph there :)
>
> I think the following work
>
> tree columns: (Array
> with: (TreeColumnModel new displayBlock: [:node | node content first asString ]; headerLabel: 'Name'; yourself)
> with: (TreeColumnModel new displayBlock: [:node | node content second asString ]; headerLabel: 'Last Name'; yourself)
> with: (TreeColumnModel new displayBlock: [:node | node content third asString ]; headerLabel: 'Age'; yourself)
> with: (TreeColumnModel new displayBlock: [:node | node content fourth asString ]; headerLabel: 'Gender'; yourself)
> with: (TreeColumnModel new displayBlock: [:node | Morph new ]; headerLabel: âMorph'; yourself))
>
> or
>
> tree columns: (Array
> with: (MorphTreeColumn new rowMorphGetSelector: [:node | node item first asString asMorph ]; headerButtonLabel: 'Name' font: nil; yourself)
> with: (MorphTreeColumn new rowMorphGetSelector: [:node | node item second asString asMorph ]; headerButtonLabel: 'Last Name' font: nil; yourself)
> with: (MorphTreeColumn new rowMorphGetSelector: [:node | node item third asString asMorph ]; headerButtonLabel: 'Age' font: nil; yourself)
> with: (MorphTreeColumn new rowMorphGetSelector: [:node | node item fourth asString asMorph ]; headerButtonLabel: 'Gender' font: nil; yourself)
> with: (MorphTreeColumn new rowMorphGetSelector: [:node | Morph new ]; headerButtonLabel: 'Morph' font: nil; yourself)).
>
> And you get something like
>
> <Screen Shot 2013-11-08 at 13.58.51.png>
>
> Ben
>
> On 08 Nov 2013, at 13:45, prova email <prova213(a)hotmail.it> wrote:
>
> Yes Clement, i've got your .st file. I saw it in Nested Layout thread. I file in it in Pharo and i see that is not as good as a fashion window is. Maybe Morphic is the right solution but, in that way, we are leaving the idea of Bahman, and the 2nd Spec Tuto is in danger!
>
> However, you asked to Ben the same question that i did: can i put some widgets in these cells or only String?
>
> Thanks again!
> Paolo
>
> From: bera.clement(a)gmail.com
> Date: Fri, 8 Nov 2013 12:51:06 +0100
> To: pharo-users(a)lists.pharo.org
> Subject: Re: [Pharo-users] Spec - Grid/Table Layout
>
> Ben answered in another thread:
>
> About table, I have an example which will be running soon in Pharo (the changes are waiting to be integrated)
>
> tree := TreeModel new.
> tree openWithSpec.
>
> tree columns: (Array
> with: (TreeColumnModel new displayBlock: [:node | node content first asString ]; headerLabel: 'Name'; yourself)
> with: (TreeColumnModel new displayBlock: [:node | node content second asString ]; headerLabel: 'Last Name'; yourself)
> with: (TreeColumnModel new displayBlock: [:node | node content third asString ]; headerLabel: 'Age'; yourself)
> with: (TreeColumnModel new displayBlock: [:node | node content fourth asString ]; headerLabel: 'Gender'; yourself)).
>
> tree roots: {
> {'Benjamin'.'Van Ryseghem'.'26'.'M'}.
> {'Pamela'.'Anderson'.'Far too much'.'F'}
> }
>
>
> Right now, you can get the same by
> - adding MorphTreeAdapter>>#columns:
> columns: columns
> self widgetDo: [ :w |
> w columns: columns.
> w resizerChanged.
> w updateList ]
>
> And then evaluating:
>
> tree := TreeModel new.
> tree openWithSpec.
>
> tree columns: (Array
> with: (MorphTreeColumn new rowMorphGetSelector: [:node | node item first asString asMorph ]; headerButtonLabel: 'Name' font: nil; yourself)
> with: (MorphTreeColumn new rowMorphGetSelector: [:node | node item second asString asMorph ]; headerButtonLabel: 'Last Name' font: nil; yourself)
> with: (MorphTreeColumn new rowMorphGetSelector: [:node | node item third asString asMorph ]; headerButtonLabel: 'Age' font: nil; yourself)
> with: (MorphTreeColumn new rowMorphGetSelector: [:node | node item fourth asString asMorph ]; headerButtonLabel: 'Gender' font: nil; yourself)).
>
> tree roots: {
> {'Benjamin'.'Van Ryseghem'.'26'.'M'}.
> {'Pamela'.'Anderson'.'Far too much'.'F'}
> }
>
> Ben
>
> Ben, in each cell, can we put something else than a String ? If so, can you add an example in the code above ? Thanks.
>
> I guess doing Ben's solution is the best. I did it with nested layout but it is definitely not as good (see file in attachment, add it in your image then evaluate SpecTable new).
>
>
> 2013/11/8 prova email <prova213(a)hotmail.it>
> Hi Clement;
>
> I did the Spec tuto made by Bahman (great tuto). As him, i'd like to put some widgets into it. Is it possible? Maybe with the method "items:"? I don't know if the solution that Ben give to us (use Morphic instead of Spec) is suitable, that's because his UI looks like a list that accept only string. Maybe i'm wrong, can you give us more explanations? Or is it something new for you too?
>
> Thanks for your help!
> Paolo
>
> From: bera.clement(a)gmail.com
> Date: Thu, 7 Nov 2013 10:04:51 +0100
> To: Bahman(a)bahmanm.com; pharo-users(a)lists.pharo.org
> Subject: Re: [Pharo-users] Spec - Grid/Table Layout
>
>
> Hello,
>
> Actually I had the same problem, I think the best widget that exists for that right now is MultiColumnListModel.
>
> For example, in the senders window (in attachment), the top panel is a MultiColumnListModel. You can have as many lines and as many columns as you want.
>
> We do not have yet a tableLayout, but we miss it. If you plan to implement it, we will be interested in integrating it into Pharo.
>
> Ben can advise you on how to implement that.
>
>
>
>
> 2013/11/7 Bahman Movaqar <Bahman(a)bahmanm.com>
> Hi all,
>
> Is there a grid/table layout available in Spec? Something like an HTML
> table or Swing's GridLayout? If not, how may I achieve such a
> functionality?
>
> I'd appreciate any hints/pointers.
>
> --
> Bahman Movaqar (http://BahmanM.com)
>
> ERP Evaluation, Implementation & Deployment Consultant
> PGP Key ID: 0x6AB5BD68 (keyserver2.pgp.com)
Nov. 11, 2013
Re: [Pharo-users] Spec - Grid/Table Layout
by prova email
Hi Ben, are you sure that the message "widgetDo:" is the right one? It's not a message that my object looks to understand. Thanks in advance.Paolo
From: Benjamin.VanRyseghem.Pharo(a)gmail.com
Date: Fri, 8 Nov 2013 14:34:18 +0100
To: pharo-users(a)lists.pharo.org
Subject: Re: [Pharo-users] Spec - Grid/Table Layout
It is definitely defined in TreeModel :)
Ben
On 08 Nov 2013, at 14:29, prova email <prova213(a)hotmail.it> wrote:Very very very good Ben, thanks a lot. Last question: you use the "columns:" message, but it's not defined in TreeModel. You defined it hereMorphTreeAdapter>>#columns: columns: columns self widgetDo: [ :w | w columns: columns. w resizerChanged. w updateList ]
in the brand new Class MorphTreeAdapter. What's the difference between define columns: here instead of in the TreeModel class?Great job and thank you!Paolo
From: Benjamin.VanRyseghem.Pharo(a)gmail.com
Date: Fri, 8 Nov 2013 14:15:46 +0100
To: pharo-users(a)lists.pharo.org
Subject: Re: [Pharo-users] Spec - Grid/Table Layout
tree := TreeModel new.tree openWithSpec.
tree columns: (Array with: (MorphTreeColumn new rowMorphGetSelector: [:node | node item first asString asMorph ]; headerButtonLabel: 'Name' font: nil; yourself) with: (MorphTreeColumn new rowMorphGetSelector: [:node | node item second asString asMorph ]; headerButtonLabel: 'Last Name' font: nil; yourself) with: (MorphTreeColumn new rowMorphGetSelector: [:node | node item third asString asMorph ]; headerButtonLabel: 'Age' font: nil; yourself) with: (MorphTreeColumn new rowMorphGetSelector: [:node | node item fourth asString asMorph ]; headerButtonLabel: 'Gender' font: nil; yourself) with: (MorphTreeColumn new rowMorphGetSelector: [:node | (ButtonModel new label: 'Yes we can') buildWithSpec hResizing: #spaceFill]; headerButtonLabel: 'Morph' font: nil; yourself)). tree roots: { {'Benjamin'.'Van Ryseghem'.'26'.'M'}. {'Pamela'.'Anderson'.'Far too much'.'F'}} Ben
On 08 Nov 2013, at 14:05, prova email <prova213(a)hotmail.it> wrote:Yes Ben, too much threads! That's why i'm a little bit confused! That's what i understood: i've got two roads-> use TreeModel as you did with Pamela Anderson or use the simple and nested SpecLayout (SpecLayout composed) as Clement did.If in your TreeModel i can put a RadioButtonModel or a ButtonModel or so on... we got the deal!
Paolo
From: Benjamin.VanRyseghem.Pharo(a)gmail.com
Date: Fri, 8 Nov 2013 13:59:51 +0100
To: pharo-users(a)lists.pharo.org
Subject: Re: [Pharo-users] Spec - Grid/Table Layout
I guess too much threads :)
I answer this in another thread I think :P
the block provided to displayBlock:/rowMorphGetSelector: can return anything understanding asMorph.So you can return any custom morph there :)
I think the following work
tree columns: (Array
with: (TreeColumnModel new displayBlock: [:node | node content first asString ]; headerLabel: 'Name'; yourself)
with: (TreeColumnModel new displayBlock: [:node | node content second asString ]; headerLabel: 'Last Name'; yourself)
with: (TreeColumnModel new displayBlock: [:node | node content third asString ]; headerLabel: 'Age'; yourself)
with: (TreeColumnModel new displayBlock: [:node | node content fourth asString ]; headerLabel: 'Gender'; yourself) with: (TreeColumnModel new displayBlock: [:node | Morph new ]; headerLabel: âMorph'; yourself))
or
tree columns: (Array with: (MorphTreeColumn new rowMorphGetSelector: [:node | node item first asString asMorph ]; headerButtonLabel: 'Name' font: nil; yourself) with: (MorphTreeColumn new rowMorphGetSelector: [:node | node item second asString asMorph ]; headerButtonLabel: 'Last Name' font: nil; yourself) with: (MorphTreeColumn new rowMorphGetSelector: [:node | node item third asString asMorph ]; headerButtonLabel: 'Age' font: nil; yourself) with: (MorphTreeColumn new rowMorphGetSelector: [:node | node item fourth asString asMorph ]; headerButtonLabel: 'Gender' font: nil; yourself) with: (MorphTreeColumn new rowMorphGetSelector: [:node | Morph new ]; headerButtonLabel: 'Morph' font: nil; yourself)).And you get something like
<Screen Shot 2013-11-08 at 13.58.51.png>Ben
On 08 Nov 2013, at 13:45, prova email <prova213(a)hotmail.it> wrote:Yes Clement, i've got your .st file. I saw it in Nested Layout thread. I file in it in Pharo and i see that is not as good as a fashion window is. Maybe Morphic is the right solution but, in that way, we are leaving the idea of Bahman, and the 2nd Spec Tuto is in danger!
However, you asked to Ben the same question that i did: can i put some widgets in these cells or only String?
Thanks again!Paolo
From: bera.clement(a)gmail.com
Date: Fri, 8 Nov 2013 12:51:06 +0100
To: pharo-users(a)lists.pharo.org
Subject: Re: [Pharo-users] Spec - Grid/Table Layout
Ben answered in another thread:
About table, I have an example which will be running soon in Pharo (the changes are waiting to be integrated)
tree := TreeModel new.tree openWithSpec.
tree columns: (Array with: (TreeColumnModel new displayBlock: [:node | node content first asString ]; headerLabel: 'Name'; yourself) with: (TreeColumnModel new displayBlock: [:node | node content second asString ]; headerLabel: 'Last Name'; yourself) with: (TreeColumnModel new displayBlock: [:node | node content third asString ]; headerLabel: 'Age'; yourself) with: (TreeColumnModel new displayBlock: [:node | node content fourth asString ]; headerLabel: 'Gender'; yourself)). tree roots: { {'Benjamin'.'Van Ryseghem'.'26'.'M'}. {'Pamela'.'Anderson'.'Far too much'.'F'}}
Right now, you can get the same by - adding MorphTreeAdapter>>#columns: columns: columns self widgetDo: [ :w | w columns: columns. w resizerChanged. w updateList ]
And then evaluating:
tree := TreeModel new.tree openWithSpec.
tree columns: (Array with: (MorphTreeColumn new rowMorphGetSelector: [:node | node item first asString asMorph ]; headerButtonLabel: 'Name' font: nil; yourself) with: (MorphTreeColumn new rowMorphGetSelector: [:node | node item second asString asMorph ]; headerButtonLabel: 'Last Name' font: nil; yourself) with: (MorphTreeColumn new rowMorphGetSelector: [:node | node item third asString asMorph ]; headerButtonLabel: 'Age' font: nil; yourself) with: (MorphTreeColumn new rowMorphGetSelector: [:node | node item fourth asString asMorph ]; headerButtonLabel: 'Gender' font: nil; yourself)). tree roots: { {'Benjamin'.'Van Ryseghem'.'26'.'M'}. {'Pamela'.'Anderson'.'Far too much'.'F'}}
Ben
Ben, in each cell, can we put something else than a String ? If so, can you add an example in the code above ? Thanks.
I guess doing Ben's solution is the best. I did it with nested layout but it is definitely not as good (see file in attachment, add it in your image then evaluate SpecTable new).
2013/11/8 prova email <prova213(a)hotmail.it>
Hi Clement;
I did the Spec tuto made by Bahman (great tuto). As him, i'd like to put some widgets into it. Is it possible? Maybe with the method "items:"? I don't know if the solution that Ben give to us (use Morphic instead of Spec) is suitable, that's because his UI looks like a list that accept only string. Maybe i'm wrong, can you give us more explanations? Or is it something new for you too?
Thanks for your help!Paolo
From: bera.clement(a)gmail.com
Date: Thu, 7 Nov 2013 10:04:51 +0100
To: Bahman(a)bahmanm.com; pharo-users(a)lists.pharo.org
Subject: Re: [Pharo-users] Spec - Grid/Table Layout
Hello,
Actually I had the same problem, I think the best widget that exists for that right now is MultiColumnListModel.
For example, in the senders window (in attachment), the top panel is a MultiColumnListModel. You can have as many lines and as many columns as you want.
We do not have yet a tableLayout, but we miss it. If you plan to implement it, we will be interested in integrating it into Pharo.
Ben can advise you on how to implement that.
2013/11/7 Bahman Movaqar <Bahman(a)bahmanm.com>
Hi all,
Is there a grid/table layout available in Spec? Something like an HTML
table or Swing's GridLayout? If not, how may I achieve such a
functionality?
I'd appreciate any hints/pointers.
--
Bahman Movaqar (http://BahmanM.com)
ERP Evaluation, Implementation & Deployment Consultant
PGP Key ID: 0x6AB5BD68 (keyserver2.pgp.com)
Nov. 11, 2013
Re: [Pharo-users] SerialPlugin on MacOS
by Bernat Romagosa
Thanks guys,
files.pharo.org is down right now
I'll try with a newer VM as soon as it's up again :)
2013/11/9 Stéphane Ducasse <stephane.ducasse(a)inria.fr>
>
> On Nov 9, 2013, at 2:19 PM, Camillo Bruni <camillobruni(a)gmail.com> wrote:
>
> > Luc proposed a pull request on github
> > - got validated by travis
> > - I integrated it into the master branch
> > - I pushed the changes to the develop branch
> >
> > so the vmLatest should include the fixes
>
> I like the process and that esteban releases some steam :)
>
> Stef
>
> >
> > On 2013-11-09, at 13:56, Stéphane Ducasse <stephane.ducasse(a)inria.fr>
> wrote:
> >> Esteban
> >>
> >> we should organize some sessions where you show to people what you are
> doing and see how we
> >> should distribute and share load.
> >>
> >> Stef
> >>
> >> On Nov 9, 2013, at 12:29 PM, Esteban Lorenzano <estebanlm(a)gmail.com>
> wrote:
> >>
> >>> Hi,
> >>>
> >>> it is "stable" but AFAIK it does not includes the latest fix for
> SerialPlugin.
> >>> So many things to do when I come back... :)
> >>>
> >>> Esteban
> >>>
> >>>
> >>> On Nov 5, 2013, at 8:27 AM, Bernat Romagosa <
> tibabenfortlapalanca(a)gmail.com> wrote:
> >>>
> >>>> Hi Luc,
> >>>>
> >>>> Smalltalk vm version reports:
> >>>>
> >>>> 'NBCoInterpreter NativeBoost-CogPlugin-EstebanLorenzano.18 uuid:
> a53445f9-c0c0-4015-97a3-be7db8d9ed6b Mar 13 2013
> >>>> NBCogit NativeBoost-CogPlugin-EstebanLorenzano.18 uuid:
> a53445f9-c0c0-4015-97a3-be7db8d9ed6b Mar 13 2013
> >>>> git://gitorious.org/cogvm/blessed.git Commit:
> 412abef33cbed05cf1d75329e451d71c0c6aa5a7 Date: 2013-03-13 17:48:50 +0100
> By: Esteban Lorenzano <estebanlm(a)gmail.com> Jenkins build #14535
> >>>> '
> >>>>
> >>>> It's the one listed as "latest" at the downloads section in
> pharo-project.org
> >>>>
> >>>> Cheers,
> >>>> Bernat.
> >>>>
> >>>>
> >>>> 2013/11/5 Luc Fabresse <luc.fabresse(a)gmail.com>
> >>>>
> >>>>
> >>>> 2013/11/5 Luc Fabresse <luc.fabresse(a)gmail.com>
> >>>> Hi Bernat,
> >>>>
> >>>> Which VM version?
> >>>> because MacOsX and Linux now use the same C part of the SerialPlugin.
> >>>> So if it works on Linux, it be the same on OsX.
> >>>> but I have not tried.
> >>>>
> >>>> yes we only use Linux here for serial stuff.
> >>>>
> >>>>
> >>>> do you use the right protName?
> >>>>
> >>>> Cheers,
> >>>>
> >>>> Luc
> >>>>
> >>>>
> >>>> 2013/11/5 Bernat Romagosa <tibabenfortlapalanca(a)gmail.com>
> >>>> Hi list,
> >>>>
> >>>> Developing a multi-platform application is not so easy when you have
> to deal with hardware it seems...
> >>>>
> >>>> So I'm having this PrimitiveFailed error on MacOS, using the latest
> stable VM listed on the pharo-project website on Pharo20:
> >>>>
> >>>> PrimitiveFailed: primitive
> #primWritePortByName:from:startingAt:count: in SerialPort failed
> >>>>
> >>>> The same code works fine both in Gnu/Linux and Win32, so I'm guessing
> it's a problem with the serial plugin included in this VM. Any ideas?
> >>>>
> >>>> Cheers,
> >>>> Bernat.
> >>>>
> >>>> --
> >>>> Bernat Romagosa.
> >>>>
> >>>>
> >>>>
> >>>>
> >>>>
> >>>> --
> >>>> Bernat Romagosa.
> >>>
> >>
> >
> >
>
>
>
--
Bernat Romagosa.
Nov. 11, 2013
Re: [Pharo-users] Pharo VM + Travis Validation
by Tudor Girba
Thanks, indeed!
Doru
On Sun, Nov 10, 2013 at 12:41 PM, Stéphane Ducasse <
stephane.ducasse(a)inria.fr> wrote:
> Thanks Camillo!
> Now pay attention to your PhD, please.
>
>
> Stef
> On Nov 9, 2013, at 10:25 PM, Camillo Bruni <camillobruni(a)gmail.com> wrote:
>
> > I finished the new setup for the Pharo VM github repository [1]
> > - renamed codegen-scripts -> scripts
> > - separate setup scripts for linux (more to come later)
> > - added scripts/build.sh which builds the VM automatically under linux
> > - generating version info
> > - dowloading fresh 2.0 image
> > - installing VMMaker from scratch from the repository
> > - added scripts/test.sh which downloads a test image and runs it with
> the freshly built VM
> > - complete travis validation [2]
> >
> > Missing Goodies:
> > - OSX travis configuration
> > - OSX setup scripts (based on homebrew + XCode installation checks)
> >
> > I would like to follow a pull-request based contribution, now with the
> > travis validation in place this is very comfortable! This way it should
> be
> > much easier for non-core people to contribute something simple.
> >
> > Note that with travis you get free validation for your own fork / branch
> [3]!
> >
> > [1] https://github.com/pharo-project/pharo-vm/
> > [2] https://travis-ci.org/pharo-project/pharo-vm/
> > [3] https://travis-ci.org/camillobruni/pharo-vm/
>
>
>
--
www.tudorgirba.com
"Every thing has its own flow"
Nov. 10, 2013
Hyperion (vector graphics editor and GUI designer using Athens)
by kilon alios
Hey guys I would like to announce my new Pharo project "Hyperion".
Hyperion is going to be a vector graphics editor with 2 goals. The first
goal is to allow you to make your own vector graphics that you will be able
to export to SVG format and other formats with similar functionality to
Inkscape. The second goal is for Hyperion to be used not only for vector
graphics but also as a GUI designer as well, which means the vector
graphics produced will be interactive and the user will define the
interaction.
Hyperion is based on Athens and Morpheas. Athens is the well known vector
graphics library for Pharo , Morpheas will be a GUI api I am making that
has the goal of simplifying Morphic and making it more friendly with GUI
designers (Hyperion) and custom look GUIs.
As a first step I implemented the ability to move the end point of a line
around using the mouse. This functionality though far less powerful than
Inkscape (and probably nowhere near its 1/1000 functionality) its the
foundation that most of the functionality of Hyperion will be based on.
Probably it may be too early to announce it but nonetheless I decided to do
so for people that can offer help , advice and direction.
You can find Hyperion in Smalltalkhub here
http://www.smalltalkhub.com/#!/~kilon/Hyperion though there is very little
to show right now (just fetch latest commit and open a workspace and do
"Hyperion open"). I do hope however that in 6 months I have something
substantial to show and maybe in a year or so be able to release version 1.
I will report back once per month with my progress.
Nov. 10, 2013