diff --git a/src/src/Rendering/Legend/FastCornerAnnotationActor.cpp b/src/src/Rendering/Legend/FastCornerAnnotationActor.cpp index 8af331a..13fee1c 100644 --- a/src/src/Rendering/Legend/FastCornerAnnotationActor.cpp +++ b/src/src/Rendering/Legend/FastCornerAnnotationActor.cpp @@ -9,7 +9,9 @@ #include vtkStandardNewMacro(FastCornerAnnotationActor); - +namespace{ + const char* FONT_FILE_PATH = "C:/Windows/Fonts/simhei.ttf"; +} FastCornerAnnotationActor::FastCornerAnnotationActor() : vtkProp(){ for (int i = 0; i < 8; ++i) { @@ -17,8 +19,8 @@ FastCornerAnnotationActor::FastCornerAnnotationActor() Actors[i]->Register(this); Actors[i]->SetTextScaleModeToNone(); Actors[i]->SetUseBorderAlign(true); - Actors[i]->GetTextProperty()->SetFontFamilyToCourier(); - Actors[i]->GetTextProperty()->SetFontSize(6); + Actors[i]->GetTextProperty()->SetFontFamily(VTK_FONT_FILE); + Actors[i]->GetTextProperty()->SetFontFile(FONT_FILE_PATH); Actors[i]->GetTextProperty()->BoldOn(); Actors[i]->GetTextProperty()->ShadowOn(); Actors[i]->GetActualPositionCoordinate()->SetCoordinateSystemToDisplay();