Hello,
We are moving Moose to SmalltalkHub and once the projects in Moose moved
and tested, we will port Moose to Pharo 2.0. Stef has volunteered to move
XMLSupport to SThub and update configs for both Pharo 1.4 and Pharo 2.0.
What do you think because it is important to have XMLSupport on a reliable
repo.
Usman
Scenario : I have an EyeSee chart that is updated from user input.
Problem: The EyeSee chart does not update. There are two methods (AFAIK) to
update glamour browser pane and its contents: explicitly send update
message to the pane or new transmission to the port of the pane to be
updated. Now, the first method does not work for EyeSee (may be a bug, i
suggested a fix yesterday). The second method requires that transmissions
are triggered but since Merlin is outside Glamour, I have to fake a
transmission on a dummy port (I tried that but when I execute my browser,
the dummy port is nil). I spent several hours looking into ports and their
transmissions but couldn't obtain a workable solution for my problem. Here
is a mock executable code to see what I am trying to achieve.
| browser aModel myColor|
browser := GLMDashboard new.
browser title: 'Customizable EyeSee Chart Example'.
browser addPaneNamed: #chart1 extent: 600@600.
myColor := Color green.
browser transmit
to: #chart1;
andShow: [ :a |
a eyesee
title: 'Sample bar chart';
diagram: [:renderer :x |
(renderer kiviat)
borderWidth: 1;
radius: 150;
models: {#(8 10 1). #(7 2 10). #(3 10 8)};
metrics: {#first. #second. #last. [ :each | each first + 2]};
maxs: {[ :model | 10]. [ :model | 10]. [ :model | 10]. [ :model | 10].};
mins: {[ :model | 1]. [ :model | 1]. [ :model | 1]. [ :model | 1]};
roundedBorder: true;
backgroundColor: myColor;
displayLegend: true;
kiviatBackground: true;
useColors: ESAbstractDiagram strongColorsTransparent];
act: [
| wizardControl wizardPane1 dropListPart|
wizardControl := WizardControl new.
wizardControl renderer: MerlinMorphicWizardRenderer new.
wizardPane1 := WizardSinglePane new.
dropListPart := DropListPart new list: #(red black green); yourself.
wizardPane1 row: dropListPart associatedTo: #color.
wizardControl addPane: wizardPane1.
wizardControl atEndDo: [ :aDictionaryOfOutputs |
myColor := aDictionaryOfOutputs at: #color.
(browser paneNamed: #chart1) update ].
wizardControl open.
] entitled: 'Parameterize Color'.
].
browser openOn: #(1 2 3 4 5 6 7 8). "can't put color in the input model"
Can you please have a look and see if I am missing something?
regards,
Usman
Hello,
I think it would be good to include this example in GlamourExamples. There
are some more in MooseBrowsers implemented by André.
| browser aModel|
browser := GLMDashboard new.
browser title: 'Customizable EyeSee Chart Example'.
browser addPaneNamed: #firstInput; addPaneNamed: #chart1 extent: 300@300.
browser transmit to: #firstInput; andShow: [ :a |
a dropDownList
title: 'Colors';
display: [ :model | model first ];
selectedIndex: 1
].
browser transmit
to: #chart1;
fromOutsidePort: #entity; from: #firstInput;
andShow: [ :a |
a eyesee
title: 'Sample bar chart';
diagram: [:renderer :model :color |
renderer verticalBarDiagram
y: #yourself;
defaultColor: color;
models: model second;
width: 200;
height: 150;
baseAxisLine.
renderer interaction popupText: #yourself ]].
aModel := Array
with: {Color black. Color red. Color green}
with: #(1 2 3 4 5 6 7 8).
browser openOn: aModel.
I am moving EyeSee from squeaksource to SThub. EyeSee has a dependency
on ShapeST80 (ss/ShapeST80). Should I move this project to Moose team or is
this project used somewhere independent of EyeSee?
usman
As the subject suggests, moose repo on squeaksource has been completely
moved to SThub. Now, we distinguish two types of package in
squeaksource/Moose:
- the packages from the repo loaded by the current moose configuration are
moved to Moose project on SThub.
- the packages not loaded by the current moose config are moved to
MooseArchive project on SThub (to be sure that we do not lose code).
ConfigurationOfMoose cannot be updated and tested unless all peripheral
tools (Mondrian/XMLSupport/etc.) are moved to SThub.
So, we are first moving and updating leaves before updating and testing the
config of trunk.
So, now remaining projects (in the coreDefault: baseline of Moose):
Mondrian, MooseAlgos, Glamour, PetitParser, XMLSupport.
I've already downloaded all packages of Mondrian, tomorrow I'll push them
and update the config.
The ones that require more effort in terms of organization: Glamour and
PetitParser.
So, may be during of the next week we can start loading the first basic
config of moose (after some cleanup: exclude DSM, Smalldude, Nile, etc.)
loadable from STHub and it would be good to make it rapid otherwise, if
someone needs to push some changes in moose and (s)he starts doing it on
SS, it'll be a mess.
usman
Currently, an EyeSee chart does not update itself when its pane is updated
in Glamour. I think the problem comes from the fact that erroneously the
presentation is assigned a new diagram block instead of a new renderer.
This code fixes this problem. Can I integrate it in glamour?
GLMMorphicEyeSeeRenderer >> actOnPresentationUpdate: ann
"ann presentation diagram: ESDiagramRenderer new."
ann presentation eyeseeRenderer: ESDiagramRenderer new.
canvasScrollPane scroller removeMorph: canvasScrollPane scroller submorphs
first.
self eyeseeCanvasFor: ann presentation
- moved the code of the both to SThub
- updated the config
- tested in 1.4 (all tests green)
- tested in 2.0
1. Apparently, BlockContext is removed in 2.0 so eyeSeeValue: cannot be
loaded from EyeSee in 2.0.
2. All tests green except ESExamplesTest>>testSmoke
Should I open bug entries for these?
Usman