[opensource-dev] Review Request: VWR-22220 Chat preferences > font size should increase size of input text as well

Vadim ProductEngine vsavchuk at productengine.com
Thu Feb 17 10:03:34 PST 2011



> On Feb. 15, 2011, 6:40 a.m., Vadim ProductEngine wrote:
> > indra/newview/llchatbar.h, line 83
> > <http://codereview.secondlife.com/r/139/diff/4/?file=790#file790line83>
> >
> >     Use tabs for indentation, not spaces.
> >     
> >     This note seems to apply to all modified lines in this patch.
> 
> Jonathan Yap wrote:
>     Using spaces is specified in the coding standard:
>     http://wiki.secondlife.com/wiki/Coding_standard#Indentation
>     This preference was made explicit on Feb 3.

Hmmm. This is news to me. Ok, please use tabs anyway to be consistent with surrounding code.


> On Feb. 15, 2011, 6:40 a.m., Vadim ProductEngine wrote:
> > indra/newview/llchatbar.cpp, lines 543-549
> > <http://codereview.secondlife.com/r/139/diff/4/?file=791#file791line543>
> >
> >     Do you only update font size on focus changes?
> >     Why?
> >     That doesn't look right to me.
> 
> Jonathan Yap wrote:
>     It might not look/feel right, but the only downside to doing it this way is the message "Click here to chat" is not immediately updated.
>     
>     If you are in the middle of typing in the chat input box and change the size preference you will have to click back on the box to continue typing, at which point the new font size is updated in the box.
>     
>     The upside to doing it this way is a test for a font change is not being performed every frame or every keystroke.  Oz is happy with it working this way.

It's not the only (and not the best) way to avoid excessive updates. For example, you can subscribe to a setting change.
Anyway, this should be implemented with some kind of callback, so that updates happen in time.


- Vadim


-----------------------------------------------------------
This is an automatically generated e-mail. To reply, visit:
http://codereview.secondlife.com/r/139/#review362
-----------------------------------------------------------


On Feb. 15, 2011, 10:04 a.m., Jonathan Yap wrote:
> 
> -----------------------------------------------------------
> This is an automatically generated e-mail. To reply, visit:
> http://codereview.secondlife.com/r/139/
> -----------------------------------------------------------
> 
> (Updated Feb. 15, 2011, 10:04 a.m.)
> 
> 
> Review request for Viewer.
> 
> 
> Summary
> -------
> 
> This is a request for help.  I am trying to learn more about c++ and how variables in one class are accessed from another.  For someone who knows what they are doing this is probably a pretty easy question.
> 
> I have been able to set the font size on the chat input box when it is created in llbottomtray.cpp.  I would like to do the same thing when someone clicks in that box to input text; it is possible they have changed the font setting and I would like to apply the size there as well, but I am stuck on how to do this.  I think the right place to do this is in llchatbar.cpp/LLChatBar::onInputEditorGainFocus().
> 
> I have tried all kinds of wrong ways but at this point am stymied.
> 
> Exact steps on how to proceed would be appreciated.
> 
> 
> This addresses bug vwr-22220.
>     http://jira.secondlife.com/browse/vwr-22220
> 
> 
> Diffs
> -----
> 
>   indra/newview/llbottomtray.h 3d2e71443c58 
>   indra/newview/llbottomtray.cpp 3d2e71443c58 
> 
> Diff: http://codereview.secondlife.com/r/139/diff
> 
> 
> Testing
> -------
> 
> 
> Thanks,
> 
> Jonathan
> 
>

-------------- next part --------------
An HTML attachment was scrubbed...
URL: http://lists.secondlife.com/pipermail/opensource-dev/attachments/20110217/9c3a5641/attachment.htm 


More information about the opensource-dev mailing list