[Libreoffice-commits] core.git: chart2/source
xukai
xukai at multicorewareinc.com
Tue Sep 23 07:59:39 PDT 2014
chart2/source/view/charttypes/GL3DBarChart.cxx | 8 ++++----
1 file changed, 4 insertions(+), 4 deletions(-)
New commits:
commit 57cc338ddfd2fcca35641ef9f49f13caac932754
Author: xukai <xukai at multicorewareinc.com>
Date: Fri Sep 19 13:10:57 2014 +0800
Using 3D fonts
Change-Id: If6cdece9f100f51b7a69ac4be4e316fb9c9928d5
Reviewed-on: https://gerrit.libreoffice.org/11535
Reviewed-by: Kohei Yoshida <libreoffice at kohei.us>
Tested-by: Kohei Yoshida <libreoffice at kohei.us>
diff --git a/chart2/source/view/charttypes/GL3DBarChart.cxx b/chart2/source/view/charttypes/GL3DBarChart.cxx
index 0604f0e..b863dee 100644
--- a/chart2/source/view/charttypes/GL3DBarChart.cxx
+++ b/chart2/source/view/charttypes/GL3DBarChart.cxx
@@ -1164,9 +1164,9 @@ void GL3DBarChart::addMovementScreenText(sal_uInt32 nBarId)
rBarInfo.maPos.y + BAR_SIZE_Y / 2.0f,
rBarInfo.maPos.z);
OUString aBarValue = OUString("Value: ") + OUString::number(rBarInfo.mnVal);
- maScreenTextShapes.push_back(new opengl3D::ScreenText(mpRenderer.get(), *mpTextCache, aBarValue, glm::vec4(0.0f, 0.0f, 1.0f, 0.0f), CALC_POS_EVENT_ID));
+ maScreenTextShapes.push_back(new opengl3D::ScreenText(mpRenderer.get(), *mpTextCache, aBarValue, glm::vec4(0.0f, 0.0f, 1.0f, 0.0f), CALC_POS_EVENT_ID, true));
const opengl3D::TextCacheItem& rTextCache = mpTextCache->getText(aBarValue);
- float nRectWidth = (float)rTextCache.maSize.Width() / (float)rTextCache.maSize.Height() * 0.03;
+ float nRectWidth = (float)rTextCache.maSize.Width() / (float)rTextCache.maSize.Height() * 0.015;
opengl3D::ScreenText* pScreenText = static_cast<opengl3D::ScreenText*>(&maScreenTextShapes.back());
pScreenText->setPosition(glm::vec2(-nRectWidth / 2, 0.03f), glm::vec2(nRectWidth / 2, -0.03f), aTextPos);
}
@@ -1361,9 +1361,9 @@ void GL3DBarChart::updateScroll()
for(size_t i = 0; i < aBarInfoList.size(); i++)
{
OUString aBarValue = OUString("Value: ") + OUString::number(aBarInfoList[i].mnVal);
- maScreenTextShapes.push_back(new opengl3D::ScreenText(mpRenderer.get(), *mpTextCache, aBarValue, glm::vec4(0.0f, 0.0f, 1.0f, 0.0f), CALC_POS_EVENT_ID));
+ maScreenTextShapes.push_back(new opengl3D::ScreenText(mpRenderer.get(), *mpTextCache, aBarValue, glm::vec4(0.0f, 0.0f, 1.0f, 0.0f), CALC_POS_EVENT_ID, true));
const opengl3D::TextCacheItem& rTextCache = mpTextCache->getText(aBarValue);
- float nRectWidth = (float)rTextCache.maSize.Width() / (float)rTextCache.maSize.Height() * 0.03;
+ float nRectWidth = (float)rTextCache.maSize.Width() / (float)rTextCache.maSize.Height() * 0.015;
glm::vec3 aTextPos = glm::vec3(aBarInfoList[i].maPos.x + BAR_SIZE_X / 2.0f,
aBarInfoList[i].maPos.y + BAR_SIZE_Y / 2.0f,
aBarInfoList[i].maPos.z);
More information about the Libreoffice-commits
mailing list