Hello,<br><br>Thanks for reviewing the patch.<br><br>I was not able to figure out how could we get the font zoom from gconf and to what variable should we assign that in tawindow.py.<br><br>Regards,<br>Kandarp Kaushik<br><br>
<br><div class="gmail_quote">On Wed, Sep 22, 2010 at 1:51 PM, Walter Bender <span dir="ltr"><<a href="mailto:walter.bender@gmail.com">walter.bender@gmail.com</a>></span> wrote:<br><blockquote class="gmail_quote" style="margin: 0pt 0pt 0pt 0.8ex; border-left: 1px solid rgb(204, 204, 204); padding-left: 1ex;">
<div><div></div><div class="h5">On Wed, Sep 22, 2010 at 12:15 AM, James Cameron <<a href="mailto:quozl@laptop.org">quozl@laptop.org</a>> wrote:<br>
> On Wed, Sep 22, 2010 at 09:10:21AM +0530, Kandarp Kaushik wrote:<br>
>> This patch scales the font in TA by using ZOOM_FACTOR<br>
>> set in sugar.graphics.style (SL#1858)<br>
><br>
> But the font size is set by the gconf float<br>
> /desktop/sugar/font/default_size ... available as<br>
> sugar.graphics.style.FONT_SIZE<br>
><br>
> Using ZOOM_FACTOR is too general, based on SUGAR_SCALING, and so Turtle<br>
> Art won't scale fonts in proportion to the font-size setting.<br>
><br>
>> @@ -125,16 +126,16 @@ class TurtleArtWindow():<br>
>> self.orientation = HORIZONTAL_PALETTE<br>
>> if olpc_xo_1():<br>
>> self.lead = 1.0<br>
>> - self.scale = 0.67<br>
>> + self.scale = 0.67 * ZOOM_FACTOR<br>
>> self.color_mode = '565'<br>
>> if self.running_sugar and not self.activity.new_sugar_system:<br>
>> self.orientation = VERTICAL_PALETTE<br>
>> else:<br>
>> self.lead = 1.0<br>
>> - self.scale = 1.0<br>
>> + self.scale = 1.0 * ZOOM_FACTOR<br>
>> self.color_mode = '888' # TODO: Read visual mode from gtk image<br>
>><br>
>> - self.block_scale = BLOCK_SCALE<br>
>> + self.block_scale = BLOCK_SCALE * ZOOM_FACTOR<br>
>> self.trash_scale = 0.5<br>
>> self.myblock = None<br>
>> self.nop = 'nop'<br>
>> @@ -2035,7 +2036,7 @@ class TurtleArtWindow():<br>
>> blk.spr.set_label(blk.values[0].replace('\n', RETURN))<br>
>> elif btype == 'start': # block size is saved in start block<br>
>> if value is not None:<br>
>> - self.block_scale = value<br>
>> + self.block_scale = value * ZOOM_FACTOR<br>
>> elif btype in EXPANDABLE or btype in EXPANDABLE_BLOCKS or \<br>
>> btype in EXPANDABLE_ARGS or btype == 'nop':<br>
>> if btype == 'vspace' or btype in EXPANDABLE_BLOCKS:<br>
><br>
> But it seems here you are not scaling the fonts, but rather block sizes.<br>
> I'm confused.<br>
<br>
</div></div>He is scaling the fonts and the block sizes. The original ticket was<br>
about using the gconf setting. It could be interesting to scale the<br>
blocks initially based on the zoom as well. So perhaps the patch<br>
should do both, but get the font zoom from gconf as you suggest.<br>
<br>
-walter<br>
<br>
> --<br>
<div><div></div><div class="h5">> James Cameron<br>
> <a href="http://quozl.linux.org.au/" target="_blank">http://quozl.linux.org.au/</a><br>
> _______________________________________________<br>
> Sugar-devel mailing list<br>
> <a href="mailto:Sugar-devel@lists.sugarlabs.org">Sugar-devel@lists.sugarlabs.org</a><br>
> <a href="http://lists.sugarlabs.org/listinfo/sugar-devel" target="_blank">http://lists.sugarlabs.org/listinfo/sugar-devel</a><br>
><br>
<br>
<br>
<br>
</div></div><font color="#888888">--<br>
Walter Bender<br>
Sugar Labs<br>
<a href="http://www.sugarlabs.org" target="_blank">http://www.sugarlabs.org</a><br>
</font></blockquote></div><br>