diff options
author | Richard Linden <none@none> | 2012-01-31 17:51:43 -0800 |
---|---|---|
committer | Richard Linden <none@none> | 2012-01-31 17:51:43 -0800 |
commit | c47c31fdbfb1c02de13bc7f17af1e7d173c048f3 (patch) | |
tree | 54d927b5f627103b3f87d276137d115c00afa699 /indra/newview | |
parent | adefcabd6a34d1d02ddfd1f6f208663b0667ac59 (diff) |
EXP-1513 FIX Underscore ( _ ) fails to show in first chat entry in Local Chat
Diffstat (limited to 'indra/newview')
-rw-r--r-- | indra/newview/llexpandabletextbox.cpp | 2 | ||||
-rw-r--r-- | indra/newview/llfasttimerview.cpp | 6 | ||||
-rw-r--r-- | indra/newview/llfolderview.cpp | 6 | ||||
-rw-r--r-- | indra/newview/llmemoryview.cpp | 2 | ||||
-rw-r--r-- | indra/newview/lltexturectrl.cpp | 2 | ||||
-rw-r--r-- | indra/newview/lltextureview.cpp | 16 | ||||
-rw-r--r-- | indra/newview/lltoastalertpanel.cpp | 4 | ||||
-rw-r--r-- | indra/newview/lltoastpanel.cpp | 2 | ||||
-rw-r--r-- | indra/newview/lluploaddialog.cpp | 2 | ||||
-rw-r--r-- | indra/newview/llviewertexteditor.cpp | 2 | ||||
-rw-r--r-- | indra/newview/llworldmapview.cpp | 8 | ||||
-rw-r--r-- | indra/newview/skins/default/xui/en/floater_test_toolbar.xml | 8 |
12 files changed, 30 insertions, 30 deletions
diff --git a/indra/newview/llexpandabletextbox.cpp b/indra/newview/llexpandabletextbox.cpp index 2abfbf37ca..935dcb74b0 100644 --- a/indra/newview/llexpandabletextbox.cpp +++ b/indra/newview/llexpandabletextbox.cpp @@ -55,7 +55,7 @@ public: else { width = mEditor.getDocumentView()->getRect().getWidth() - mEditor.getHPad(); - height = llceil(mStyle->getFont()->getLineHeight()); + height = mStyle->getFont()->getLineHeight(); } return true; } diff --git a/indra/newview/llfasttimerview.cpp b/indra/newview/llfasttimerview.cpp index 233038daba..9664aa7dbe 100644 --- a/indra/newview/llfasttimerview.cpp +++ b/indra/newview/llfasttimerview.cpp @@ -149,7 +149,7 @@ BOOL LLFastTimerView::handleRightMouseDown(S32 x, S32 y, MASK mask) LLFastTimer::NamedTimer* LLFastTimerView::getLegendID(S32 y) { - S32 idx = (getRect().getHeight() - y) / ((S32) LLFontGL::getFontMonospace()->getLineHeight()+2) - 5; + S32 idx = (getRect().getHeight() - y) / (LLFontGL::getFontMonospace()->getLineHeight()+2) - 5; if (idx >= 0 && idx < (S32)ft_display_idx.size()) { @@ -552,7 +552,7 @@ void LLFastTimerView::draw() // update rectangle that includes timer bars mBarRect.mLeft = xleft; mBarRect.mRight = getRect().getWidth(); - mBarRect.mTop = ytop - ((S32)LLFontGL::getFontMonospace()->getLineHeight() + 4); + mBarRect.mTop = ytop - (LLFontGL::getFontMonospace()->getLineHeight() + 4); mBarRect.mBottom = margin + LINE_GRAPH_HEIGHT; y = ytop; @@ -846,7 +846,7 @@ void LLFastTimerView::draw() tdesc = llformat("%4.2f ms", ms); x = mGraphRect.mRight - LLFontGL::getFontMonospace()->getWidth(tdesc)-5; - y = mGraphRect.mTop - ((S32)LLFontGL::getFontMonospace()->getLineHeight()); + y = mGraphRect.mTop - LLFontGL::getFontMonospace()->getLineHeight(); LLFontGL::getFontMonospace()->renderUTF8(tdesc, 0, x, y, LLColor4::white, LLFontGL::LEFT, LLFontGL::TOP); diff --git a/indra/newview/llfolderview.cpp b/indra/newview/llfolderview.cpp index 79c987fa37..2249f61435 100644 --- a/indra/newview/llfolderview.cpp +++ b/indra/newview/llfolderview.cpp @@ -255,7 +255,7 @@ LLFolderView::LLFolderView(const Params& p) LLRect new_r = LLRect(rect.mLeft + ICON_PAD, rect.mTop - TEXT_PAD, rect.mRight, - rect.mTop - TEXT_PAD - llfloor(font->getLineHeight())); + rect.mTop - TEXT_PAD - font->getLineHeight()); text_p.rect(new_r); text_p.name(std::string(p.name)); text_p.font(font); @@ -414,7 +414,7 @@ S32 LLFolderView::arrange( S32* unused_width, S32* unused_height, S32 filter_gen getRoot()->getFilter()->getShowFolderState(); S32 total_width = LEFT_PAD; - S32 running_height = mDebugFilters ? llceil(LLFontGL::getFontMonospace()->getLineHeight()) : 0; + S32 running_height = mDebugFilters ? LLFontGL::getFontMonospace()->getLineHeight() : 0; S32 target_height = running_height; S32 parent_item_height = getRect().getHeight(); @@ -1994,7 +1994,7 @@ void LLFolderView::scrollToShowItem(LLFolderViewItem* item, const LLRect& constr LLRect visible_doc_rect = mScrollContainer->getVisibleContentRect(); S32 icon_height = mIcon.isNull() ? 0 : mIcon->getHeight(); - S32 label_height = llround(getLabelFontForStyle(mLabelStyle)->getLineHeight()); + S32 label_height = getLabelFontForStyle(mLabelStyle)->getLineHeight(); // when navigating with keyboard, only move top of opened folder on screen, otherwise show whole folder S32 max_height_to_show = item->isOpen() && mScrollContainer->hasFocus() ? (llmax( icon_height, label_height ) + ICON_PAD) : local_rect.getHeight(); diff --git a/indra/newview/llmemoryview.cpp b/indra/newview/llmemoryview.cpp index 7e9c3c84a7..c0a323d6cb 100644 --- a/indra/newview/llmemoryview.cpp +++ b/indra/newview/llmemoryview.cpp @@ -220,7 +220,7 @@ void LLMemoryView::draw() S32 x, y; S32 margin = 10; - S32 texth = (S32)LLFontGL::getFontMonospace()->getLineHeight(); + S32 texth = LLFontGL::getFontMonospace()->getLineHeight(); S32 xleft = margin; S32 ytop = height - margin; diff --git a/indra/newview/lltexturectrl.cpp b/indra/newview/lltexturectrl.cpp index de22f2ae6b..e26d2e001c 100644 --- a/indra/newview/lltexturectrl.cpp +++ b/indra/newview/lltexturectrl.cpp @@ -922,7 +922,7 @@ LLTextureCtrl::LLTextureCtrl(const LLTextureCtrl::Params& p) S32 image_top = getRect().getHeight(); S32 image_bottom = BTN_HEIGHT_SMALL; S32 image_middle = (image_top + image_bottom) / 2; - S32 line_height = llround(LLFontGL::getFontSansSerifSmall()->getLineHeight()); + S32 line_height = LLFontGL::getFontSansSerifSmall()->getLineHeight(); LLTextBox::Params tentative_label_p(p.multiselect_text); tentative_label_p.name("Multiple"); diff --git a/indra/newview/lltextureview.cpp b/indra/newview/lltextureview.cpp index 1c89766b26..5b41a05f2a 100644 --- a/indra/newview/lltextureview.cpp +++ b/indra/newview/lltextureview.cpp @@ -386,7 +386,7 @@ public: Params() : texture_view("texture_view") { - S32 line_height = (S32)(LLFontGL::getFontMonospace()->getLineHeight() + .5f); + S32 line_height = LLFontGL::getFontMonospace()->getLineHeight(); changeDefault(rect, LLRect(0,0,100,line_height * 4)); } }; @@ -411,7 +411,7 @@ void LLAvatarTexBar::draw() LLVOAvatarSelf* avatarp = gAgentAvatarp; if (!avatarp) return; - const S32 line_height = (S32)(LLFontGL::getFontMonospace()->getLineHeight() + .5f); + const S32 line_height = LLFontGL::getFontMonospace()->getLineHeight(); const S32 v_offset = 0; const S32 l_offset = 3; @@ -485,7 +485,7 @@ public: Params() : texture_view("texture_view") { - S32 line_height = (S32)(LLFontGL::getFontMonospace()->getLineHeight() + .5f); + S32 line_height = LLFontGL::getFontMonospace()->getLineHeight(); changeDefault(rect, LLRect(0,0,100,line_height * 4)); } }; @@ -512,7 +512,7 @@ void LLGLTexMemBar::draw() F32 discard_bias = LLViewerTexture::sDesiredDiscardBias; F32 cache_usage = (F32)BYTES_TO_MEGA_BYTES(LLAppViewer::getTextureCache()->getUsage()) ; F32 cache_max_usage = (F32)BYTES_TO_MEGA_BYTES(LLAppViewer::getTextureCache()->getMaxUsage()) ; - S32 line_height = (S32)(LLFontGL::getFontMonospace()->getLineHeight() + .5f); + S32 line_height = LLFontGL::getFontMonospace()->getLineHeight(); S32 v_offset = (S32)((texture_bar_height + 2.2f) * mTextureView->mNumTextureBars + 2.0f); F32 total_texture_downloaded = (F32)gTotalTextureBytes / (1024 * 1024); F32 total_object_downloaded = (F32)gTotalObjectBytes / (1024 * 1024); @@ -1097,7 +1097,7 @@ void LLTextureSizeView::drawTextureSizeGraph() { if(mTextureSizeBar.size() == 0) { - S32 line_height = (S32)(LLFontGL::getFontMonospace()->getLineHeight() + .5f); + S32 line_height = LLFontGL::getFontMonospace()->getLineHeight(); mTextureSizeBar.resize(LLImageGL::sTextureLoadedCounter.size()) ; mTextureSizeBarRect.set(700, line_height * 2 + 400, 700 + mTextureSizeBar.size() * mTextureSizeBarWidth, line_height * 2) ; @@ -1140,7 +1140,7 @@ F32 LLTextureSizeView::drawTextureSizeDistributionGraph() } } - S32 line_height = (S32)(LLFontGL::getFontMonospace()->getLineHeight() + .5f); + S32 line_height = LLFontGL::getFontMonospace()->getLineHeight(); S32 left = mTextureSizeBarRect.mLeft ; S32 bottom = mTextureSizeBarRect.mBottom ; S32 right = mTextureSizeBarRect.mRight ; @@ -1222,7 +1222,7 @@ void LLTextureSizeView::drawTextureCategoryGraph() { if(mTextureSizeBar.size() == 0) { - S32 line_height = (S32)(LLFontGL::getFontMonospace()->getLineHeight() + .5f); + S32 line_height = LLFontGL::getFontMonospace()->getLineHeight(); mTextureSizeBar.resize(LLViewerTexture::getTotalNumOfCategories()) ; mTextureSizeBarRect.set(700, line_height * 2 + 400, 700 + mTextureSizeBar.size() * mTextureSizeBarWidth, line_height * 2) ; @@ -1267,7 +1267,7 @@ F32 LLTextureSizeView::drawTextureCategoryDistributionGraph() } } - S32 line_height = (S32)(LLFontGL::getFontMonospace()->getLineHeight() + .5f); + S32 line_height = LLFontGL::getFontMonospace()->getLineHeight(); S32 left = mTextureSizeBarRect.mLeft ; S32 bottom = mTextureSizeBarRect.mBottom ; S32 right = mTextureSizeBarRect.mRight ; diff --git a/indra/newview/lltoastalertpanel.cpp b/indra/newview/lltoastalertpanel.cpp index 0f337825e9..12ad071799 100644 --- a/indra/newview/lltoastalertpanel.cpp +++ b/indra/newview/lltoastalertpanel.cpp @@ -70,7 +70,7 @@ LLToastAlertPanel::LLToastAlertPanel( LLNotificationPtr notification, bool modal mLineEditor(NULL) { const LLFontGL* font = LLFontGL::getFontSansSerif(); - const S32 LINE_HEIGHT = llfloor(font->getLineHeight() + 0.99f); + const S32 LINE_HEIGHT = font->getLineHeight(); const S32 EDITOR_HEIGHT = 20; LLNotificationFormPtr form = mNotification->getForm(); @@ -365,7 +365,7 @@ bool LLToastAlertPanel::setCheckBox( const std::string& check_title, const std:: } const LLFontGL* font = mCheck->getFont(); - const S32 LINE_HEIGHT = llfloor(font->getLineHeight() + 0.99f); + const S32 LINE_HEIGHT = font->getLineHeight(); // Extend dialog for "check next time" S32 max_msg_width = LLToastPanel::getRect().getWidth() - 2 * HPAD; diff --git a/indra/newview/lltoastpanel.cpp b/indra/newview/lltoastpanel.cpp index fc69157a40..d2a4ce8745 100644 --- a/indra/newview/lltoastpanel.cpp +++ b/indra/newview/lltoastpanel.cpp @@ -68,7 +68,7 @@ void LLToastPanel::snapToMessageHeight(LLTextBase* message, S32 maxLineCount) if (message->getVisible()) { S32 heightDelta = 0; - S32 maxTextHeight = (S32)(message->getDefaultFont()->getLineHeight() * maxLineCount); + S32 maxTextHeight = message->getDefaultFont()->getLineHeight() * maxLineCount; LLRect messageRect = message->getRect(); S32 oldTextHeight = messageRect.getHeight(); diff --git a/indra/newview/lluploaddialog.cpp b/indra/newview/lluploaddialog.cpp index df7c5be0d6..e59064c074 100644 --- a/indra/newview/lluploaddialog.cpp +++ b/indra/newview/lluploaddialog.cpp @@ -115,7 +115,7 @@ void LLUploadDialog::setMessage( const std::string& msg) token = strtok( NULL, "\n" ); } - S32 line_height = S32( font->getLineHeight() + 0.99f ); + S32 line_height = font->getLineHeight(); S32 dialog_width = max_msg_width + 2 * HPAD; S32 dialog_height = line_height * msg_lines.size() + 2 * VPAD; diff --git a/indra/newview/llviewertexteditor.cpp b/indra/newview/llviewertexteditor.cpp index b41ed00f17..99102309a1 100644 --- a/indra/newview/llviewertexteditor.cpp +++ b/indra/newview/llviewertexteditor.cpp @@ -187,7 +187,7 @@ public: else { width = EMBEDDED_ITEM_LABEL_PADDING + mImage->getWidth() + mStyle->getFont()->getWidth(mLabel.c_str()); - height = llmax(mImage->getHeight(), llceil(mStyle->getFont()->getLineHeight())); + height = llmax(mImage->getHeight(), mStyle->getFont()->getLineHeight()); } return false; } diff --git a/indra/newview/llworldmapview.cpp b/indra/newview/llworldmapview.cpp index e50851b8e7..a20ee8686b 100644 --- a/indra/newview/llworldmapview.cpp +++ b/indra/newview/llworldmapview.cpp @@ -513,7 +513,7 @@ void LLWorldMapView::draw() TRUE, "You are here", "", - llround(LLFontGL::getFontSansSerifSmall()->getLineHeight())); // offset vertically by one line, to avoid overlap with target tracking + LLFontGL::getFontSansSerifSmall()->getLineHeight()); // offset vertically by one line, to avoid overlap with target tracking } // Draw the current agent viewing angle @@ -992,7 +992,7 @@ void LLWorldMapView::drawTracking(const LLVector3d& pos_global, const LLColor4& const S32 TEXT_PADDING = DEFAULT_TRACKING_ARROW_SIZE + 2; S32 half_text_width = llfloor(font->getWidthF32(label) * 0.5f); text_x = llclamp(text_x, half_text_width + TEXT_PADDING, getRect().getWidth() - half_text_width - TEXT_PADDING); - text_y = llclamp(text_y + vert_offset, TEXT_PADDING + vert_offset, getRect().getHeight() - llround(font->getLineHeight()) - TEXT_PADDING - vert_offset); + text_y = llclamp(text_y + vert_offset, TEXT_PADDING + vert_offset, getRect().getHeight() - font->getLineHeight() - TEXT_PADDING - vert_offset); if (label != "") { @@ -1005,7 +1005,7 @@ void LLWorldMapView::drawTracking(const LLVector3d& pos_global, const LLColor4& if (tooltip != "") { - text_y -= (S32)font->getLineHeight(); + text_y -= font->getLineHeight(); font->renderUTF8( tooltip, 0, @@ -1203,7 +1203,7 @@ void LLWorldMapView::drawIconName(F32 x_pixels, LLFontGL::NORMAL, LLFontGL::DROP_SHADOW); - text_y -= llround(LLFontGL::getFontSansSerif()->getLineHeight()); + text_y -= LLFontGL::getFontSansSerif()->getLineHeight(); // render text LLFontGL::getFontSansSerif()->renderUTF8(second_line, 0, diff --git a/indra/newview/skins/default/xui/en/floater_test_toolbar.xml b/indra/newview/skins/default/xui/en/floater_test_toolbar.xml index 067c1fed82..0c41c3ba2f 100644 --- a/indra/newview/skins/default/xui/en/floater_test_toolbar.xml +++ b/indra/newview/skins/default/xui/en/floater_test_toolbar.xml @@ -7,7 +7,7 @@ name="floater_test_toolbar" translate="false" width="500"> - <toolbar name="test_toolbar_top" + <!--<toolbar name="test_toolbar_top" button_display_mode="icons_with_text" follows="left|right|top" height="50" @@ -20,7 +20,7 @@ <command name="avatar"/> <command name="build"/> <command name="chat"/> - </toolbar> + </toolbar>--> <toolbar name="test_toolbar_left" button_display_mode="icons_with_text" follows="left|bottom|top" @@ -46,7 +46,7 @@ <command name="build"/> <command name="chat"/> </toolbar> - <toolbar name="test_toolbar_bottom" + <!--<toolbar name="test_toolbar_bottom" button_display_mode="icons_with_text" follows="left|right|bottom" height="50" @@ -58,5 +58,5 @@ <command name="avatar"/> <command name="build"/> <command name="chat"/> - </toolbar> + </toolbar>--> </floater> |