]> OCCT Git - occt.git/commitdiff
0032680: Visualization, AIS_TextLabel - Bold FontAspect doesn't work
authorkgv <kgv@opencascade.com>
Mon, 22 Nov 2021 08:01:37 +0000 (11:01 +0300)
committersmoskvin <smoskvin@opencascade.com>
Mon, 22 Nov 2021 16:04:09 +0000 (19:04 +0300)
Prs3d_TextAspect now sets Font_NOF_SERIF as default font
instead of confusig Font_NOF_ASCII_TRIPLEX (Times-Bold).
Therefore, default font now uses regular aspect, not bold.

Command vdrawtext does no more set "Courier" font by default.

src/Prs3d/Prs3d_TextAspect.cxx
src/ViewerTest/ViewerTest_ObjectCommands.cxx

index 3ff268d0bf95b309bcb18bae75b0ee06d5a232ea..e1a65bda40e821fa563c5bc56c254100e6fe4101 100644 (file)
@@ -26,7 +26,7 @@ IMPLEMENT_STANDARD_RTTIEXT(Prs3d_TextAspect, Prs3d_BasicAspect)
 // purpose  :
 // =======================================================================
 Prs3d_TextAspect::Prs3d_TextAspect()
-: myTextAspect (new Graphic3d_AspectText3d (Quantity_Color (Quantity_NOC_YELLOW), Font_NOF_ASCII_TRIPLEX, 1.0, 0.0)),
+: myTextAspect (new Graphic3d_AspectText3d (Quantity_Color (Quantity_NOC_YELLOW), Font_NOF_SERIF, 1.0, 0.0)),
   myHeight(16.0),
   myHorizontalJustification (Graphic3d_HTA_LEFT),
   myVerticalJustification (Graphic3d_VTA_BOTTOM),
index 67b894bfebea66cb08a7eb5cba6f0f026392f035..6fb51fff2d581bc94048bc14341eb675e87d368e 100644 (file)
@@ -2355,7 +2355,6 @@ static int VDrawText (Draw_Interpretor& theDI,
   {
     isNewPrs = Standard_True;
     aTextPrs = new AIS_TextLabel();
-    aTextPrs->SetFont ("Courier");
   }
 
   aTextPrs->SetText (aText);