Default font to Sans from osifont

This commit is contained in:
WandererFan
2016-06-28 09:40:03 -04:00
committed by wmayer
parent 35e833f7cd
commit 82c86b24af
6 changed files with 5 additions and 11 deletions

View File

@@ -85,12 +85,6 @@ void TechDrawGuiExport initTechDrawGui()
TechDrawGui::Workbench::init();
//TODO: is this platform independent?? should osifont be added by installer?
//Load the osifont for Drawing View
// See https://code.google.com/p/osifont/
QFontDatabase fontDB;
fontDB.addApplicationFont(QString::fromAscii(":/fonts/osifont.ttf"));
TechDrawGui::ViewProviderPage::init();
TechDrawGui::ViewProviderDrawingView::init();

View File

@@ -79,7 +79,7 @@ void QGCustomText::paint ( QPainter * painter, const QStyleOptionGraphicsItem *
//svg text is much larger than screen text. scene units(mm) vs points.
//need to scale text if going to svg.
//TODO: magic translation happens? approx: right ~8mm down: 12mm + (3mm per mm of text height)
//SVG transform matrix translation values are different for same font size + different fonts (osifont vs Ubuntu vs Arial)???
//SVG transform matrix translation values are different for same font size + different fonts (Sans vs Ubuntu vs Arial)???
// scale values are same for same font size + different fonts.
//double svgScale = 2.835; //72dpi/(25.4mm/in)
//double svgScale = 3.84; //96dpi/(25mm/in)

View File

@@ -88,7 +88,7 @@ QGIView::QGIView()
m_pen.setColor(m_colCurrent);
hGrp = App::GetApplication().GetUserParameter().GetGroup("BaseApp")->GetGroup("Preferences")->GetGroup("Mod/TechDraw");
std::string fontName = hGrp->GetASCII("LabelFont", "osifont");
std::string fontName = hGrp->GetASCII("LabelFont", "Sans");
m_font.setFamily(QString::fromStdString(fontName));
m_font.setPointSize(5.0); //scene units (mm), not points