Ok, thank you for your answer :)
I'm trying to load Glamour using the code founded on the web page :
Gofer new
squeaksource: 'Glamour';
package: 'ConfigurationOfGlamour';
load.
(Smalltalk at: #ConfigurationOfGlamour) perform: #loadDefault
But it doesn't work, it seems a method is deprecated, and it won't load the code
:s
It sounds like neewbie talks ...
Ben
On Nov 2, 2010, at 9:29 PM, Tudor Girba wrote:
Hi Benjamin,
First of all, welcome :).
Second of all, thanks for reminding me that I should update the examples with using the
new API, instead of the old one that uses showOn:. I committed a quick update of the
treeWithChildrenByLevel to give you an idea of the difference.
Coming back to your example, the problem is that the children block does not return a
collection, but an integer. If you want to see the children of a node, you need to specify
a collection with objects that will appear as children. Ideally, they should be of the
same type as the root nodes.
Cheers,
Doru
On 2 Nov 2010, at 19:12, Benjamin wrote:
Hi everybody,
I'm just discovering Glamour, and after having read examples, I've tested to
write my own browser but, as you guessed, it doesn't work and moreover the debugger
doesn't help me at all
Here is my code :
recentSetBrowser
| browser |
browser := GLMTabulator new.
browser column: #one.
browser showOn: #one; using: [
browser tree
title: 'Tree';
children: [:item :x :level |
level > 1 ifTrue: [#()] ifFalse: [item size ]]].
^browser
Here is the example :
treeWithChildrenByLevel
|browser |
browser := GLMTabulator new.
browser column: #one; column: [:c | c row: #two; row: #three].
browser showOn: #one; using: [
browser tree
title: 'Tree';
children: [:item :x :level |
level > 1 ifTrue: [#()] ifFalse: [1 to: item ] ]].
browser showOn: #two; from: #one; using: [ browser text title: 'Selection
preview' ].
browser showOn: #three; from: #one->#selectionPath; using: [
browser text title: 'Selection path preview'].
^ browser
When I run
GLMTest1 new recentSetBrowser openOn: #('lapin' 'chapeau')
the debugger answer :
'MessageNotUnderstood: SmallInteger>>collect:' ...
If someone can help me :)
Benjamin Van Ryseghem
_______________________________________________
Moose-dev mailing list
Moose-dev(a)iam.unibe.ch
https://www.iam.unibe.ch/mailman/listinfo/moose-dev
--
www.tudorgirba.com
"Live like you mean it."
_______________________________________________
Moose-dev mailing list
Moose-dev(a)iam.unibe.ch
https://www.iam.unibe.ch/mailman/listinfo/moose-dev
_______________________________________________
Moose-dev mailing list
Moose-dev(a)iam.unibe.ch