Hi Alex,
Previously I reported that the color of text does not appear as it should be, but light... You created the withoutBackground method that works but sometimes. As I display small fonts, having blurred texts does not help try this code... (1 to: 10) do: [:n | view shape rectangle borderColor:[ :each| Color blue ]. view node: n forIt: [ view node: (n * 2) using: (view shape rectangle withoutBorder withoutBackground; fontColor:[ :each| Color red ]; text:[ :e| e asString ]). ] ]. cheers, Veronica _______________________________________________ Moose-dev mailing list [hidden email] https://www.iam.unibe.ch/mailman/listinfo/moose-dev |
Hi!
I am not sure to understand. Consider the following example (to execute in a workspace): -=-=-=--=-=-=--=-=-=--=-=-=- | morphClass | morphClass := Morph subclass: #TMPMorph. morphClass compile: 'fillStyle ^ Color white'. morphClass compile: 'drawOn: aCanvas super drawOn: aCanvas. aCanvas drawString: ''1 2 3'' in: self bounds font: TextStyle defaultFont color: Color red.'. morphClass new openInHand -=-=-=--=-=-=--=-=-=--=-=-=- It gives: An example that uses the default text font in Mondrian. -=-=-=--=-=-=--=-=-=--=-=-=- | morphClass | morphClass := Morph subclass: #TMPMorph. morphClass compile: 'fillStyle ^ Color white'. morphClass compile: 'drawOn: aCanvas super drawOn: aCanvas. aCanvas drawString: ''1 2 3'' in: self bounds font: (MOBoundedShape new fontFor: MONode new) color: Color red.'. morphClass new openInHand -=-=-=--=-=-=--=-=-=--=-=-=- Which produces: Your easel script produces: I do not see any strange behavior. Can you provide a screenshot Cheers, Alexandre On 20 Jul 2010, at 11:28, Veronica Isabel Uquillas Gomez wrote: > Hi Alex, > > Previously I reported that the color of text does not appear as it should be, but light... You created the withoutBackground method that works but sometimes. > As I display small fonts, having blurred texts does not help > > try this code... > > (1 to: 10) do: [:n | > view shape rectangle > borderColor:[ :each| Color blue ]. > view node: n forIt: [ > view node: (n * 2) using: (view shape rectangle withoutBorder > withoutBackground; > fontColor:[ :each| Color red ]; > text:[ :e| e asString ]). > ] > ]. > > cheers, > Veronica > _______________________________________________ > Moose-dev mailing list > [hidden email] > https://www.iam.unibe.ch/mailman/listinfo/moose-dev _,.;:~^~:;._,.;:~^~:;._,.;:~^~:;._,.;:~^~:;._,.;: Alexandre Bergel http://www.bergel.eu ^~:;._,.;:~^~:;._,.;:~^~:;._,.;:~^~:;._,.;:~^~:;. _______________________________________________ Moose-dev mailing list [hidden email] https://www.iam.unibe.ch/mailman/listinfo/moose-dev Screen shot 2010-07-20 at 12.37.23.png (10K) Download Attachment Screen shot 2010-07-20 at 14.01.04.png (8K) Download Attachment Screen shot 2010-07-20 at 12.37.30.png (8K) Download Attachment |
Hi,
This code produces the right color. view shape rectangle withoutBorder. view node: 10 forIt: [ (1 to: 10) do: [:n | view shape rectangle borderColor:[ :each| Color blue ]. view node: n forIt: [ view node: (n * 2) using: (view shape rectangle withoutBorder withoutBackground; fontColor:[ :each| Color black ]; text:[ :e| e asString ]). ] ] ] The code without the outer node produces labels with a light color. The outer node is the one i removed to make the drawing faster, but now i have the label color problem. (1 to: 10) do: [:n | view shape rectangle borderColor:[ :each| Color blue ]. view node: n forIt: [ view node: (n * 2) using: (view shape rectangle withoutBorder withoutBackground; fontColor:[ :each| Color black ]; text:[ :e| e asString ]). ] ] Attach 2 screenshots, there you will see better the problem (name of the packages). Veronica On 20 Jul 2010, at 14:02, Alexandre Bergel wrote: > Hi! > > I am not sure to understand. > Consider the following example (to execute in a workspace): > -=-=-=--=-=-=--=-=-=--=-=-=- > | morphClass | > morphClass := Morph subclass: #TMPMorph. > morphClass compile: 'fillStyle ^ Color white'. > morphClass compile: 'drawOn: aCanvas > super drawOn: aCanvas. > aCanvas drawString: ''1 2 3'' > in: self bounds > font: TextStyle defaultFont > color: Color red.'. > morphClass new openInHand > -=-=-=--=-=-=--=-=-=--=-=-=- > It gives: > <Screen shot 2010-07-20 at 12.37.23.png> > > An example that uses the default text font in Mondrian. > > -=-=-=--=-=-=--=-=-=--=-=-=- > | morphClass | > morphClass := Morph subclass: #TMPMorph. > morphClass compile: 'fillStyle ^ Color white'. > morphClass compile: 'drawOn: aCanvas > super drawOn: aCanvas. > aCanvas drawString: ''1 2 3'' > in: self bounds > font: (MOBoundedShape new fontFor: MONode new) > color: Color red.'. > morphClass new openInHand > -=-=-=--=-=-=--=-=-=--=-=-=- > Which produces: > <Screen shot 2010-07-20 at 14.01.04.png> > > > Your easel script produces: > > <Screen shot 2010-07-20 at 12.37.30.png> > > I do not see any strange behavior. Can you provide a screenshot > > Cheers, > Alexandre > > > On 20 Jul 2010, at 11:28, Veronica Isabel Uquillas Gomez wrote: > >> Hi Alex, >> >> Previously I reported that the color of text does not appear as it should be, but light... You created the withoutBackground method that works but sometimes. >> As I display small fonts, having blurred texts does not help >> >> try this code... >> >> (1 to: 10) do: [:n | >> view shape rectangle >> borderColor:[ :each| Color blue ]. >> view node: n forIt: [ >> view node: (n * 2) using: (view shape rectangle withoutBorder >> withoutBackground; >> fontColor:[ :each| Color red ]; >> text:[ :e| e asString ]). >> ] >> ]. >> >> cheers, >> Veronica >> _______________________________________________ >> Moose-dev mailing list >> [hidden email] >> https://www.iam.unibe.ch/mailman/listinfo/moose-dev > > -- > _,.;:~^~:;._,.;:~^~:;._,.;:~^~:;._,.;:~^~:;._,.;: > Alexandre Bergel http://www.bergel.eu > ^~:;._,.;:~^~:;._,.;:~^~:;._,.;:~^~:;._,.;:~^~:;. > > > > > > _______________________________________________ > 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 |
I am working on it.
Cheers, Alexandre On 20 Jul 2010, at 14:33, Veronica Isabel Uquillas Gomez wrote: > Hi, > > This code produces the right color. > > view shape rectangle withoutBorder. > view node: 10 forIt: [ > > (1 to: 10) do: [:n | > view shape rectangle > borderColor:[ :each| Color blue ]. > view node: n forIt: [ > view node: (n * 2) using: (view shape rectangle withoutBorder > withoutBackground; > fontColor:[ :each| Color black ]; > text:[ :e| e asString ]). > ] > ] > ] > > The code without the outer node produces labels with a light color. The outer node is the one i removed to make the drawing faster, but now i have the label color problem. > > (1 to: 10) do: [:n | > view shape rectangle > borderColor:[ :each| Color blue ]. > view node: n forIt: [ > view node: (n * 2) using: (view shape rectangle withoutBorder > withoutBackground; > fontColor:[ :each| Color black ]; > text:[ :e| e asString ]). > ] > ] > > Attach 2 screenshots, there you will see better the problem (name of the packages). > > <textColor-Ok.png><textColor-blurried.png> > > > Veronica > > > > On 20 Jul 2010, at 14:02, Alexandre Bergel wrote: > >> Hi! >> >> I am not sure to understand. >> Consider the following example (to execute in a workspace): >> -=-=-=--=-=-=--=-=-=--=-=-=- >> | morphClass | >> morphClass := Morph subclass: #TMPMorph. >> morphClass compile: 'fillStyle ^ Color white'. >> morphClass compile: 'drawOn: aCanvas >> super drawOn: aCanvas. >> aCanvas drawString: ''1 2 3'' >> in: self bounds >> font: TextStyle defaultFont >> color: Color red.'. >> morphClass new openInHand >> -=-=-=--=-=-=--=-=-=--=-=-=- >> It gives: >> <Screen shot 2010-07-20 at 12.37.23.png> >> >> An example that uses the default text font in Mondrian. >> >> -=-=-=--=-=-=--=-=-=--=-=-=- >> | morphClass | >> morphClass := Morph subclass: #TMPMorph. >> morphClass compile: 'fillStyle ^ Color white'. >> morphClass compile: 'drawOn: aCanvas >> super drawOn: aCanvas. >> aCanvas drawString: ''1 2 3'' >> in: self bounds >> font: (MOBoundedShape new fontFor: MONode new) >> color: Color red.'. >> morphClass new openInHand >> -=-=-=--=-=-=--=-=-=--=-=-=- >> Which produces: >> <Screen shot 2010-07-20 at 14.01.04.png> >> >> >> Your easel script produces: >> >> <Screen shot 2010-07-20 at 12.37.30.png> >> >> I do not see any strange behavior. Can you provide a screenshot >> >> Cheers, >> Alexandre >> >> >> On 20 Jul 2010, at 11:28, Veronica Isabel Uquillas Gomez wrote: >> >>> Hi Alex, >>> >>> Previously I reported that the color of text does not appear as it should be, but light... You created the withoutBackground method that works but sometimes. >>> As I display small fonts, having blurred texts does not help >>> >>> try this code... >>> >>> (1 to: 10) do: [:n | >>> view shape rectangle >>> borderColor:[ :each| Color blue ]. >>> view node: n forIt: [ >>> view node: (n * 2) using: (view shape rectangle withoutBorder >>> withoutBackground; >>> fontColor:[ :each| Color red ]; >>> text:[ :e| e asString ]). >>> ] >>> ]. >>> >>> cheers, >>> Veronica >>> _______________________________________________ >>> Moose-dev mailing list >>> [hidden email] >>> https://www.iam.unibe.ch/mailman/listinfo/moose-dev >> >> -- >> _,.;:~^~:;._,.;:~^~:;._,.;:~^~:;._,.;:~^~:;._,.;: >> Alexandre Bergel http://www.bergel.eu >> ^~:;._,.;:~^~:;._,.;:~^~:;._,.;:~^~:;._,.;:~^~:;. >> >> >> >> >> >> _______________________________________________ >> 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 -- _,.;:~^~:;._,.;:~^~:;._,.;:~^~:;._,.;:~^~:;._,.;: Alexandre Bergel http://www.bergel.eu ^~:;._,.;:~^~:;._,.;:~^~:;._,.;:~^~:;._,.;:~^~:;. _______________________________________________ Moose-dev mailing list [hidden email] https://www.iam.unibe.ch/mailman/listinfo/moose-dev |
Free forum by Nabble | Edit this page |