EgtGeomKernel 1.5f3 :

- agg. a Text ModifyText e ChangeFont.
This commit is contained in:
Dario Sassi
2014-06-09 08:26:39 +00:00
parent bf2eb6648e
commit e9d45f84df
5 changed files with 74 additions and 0 deletions
+32
View File
@@ -721,6 +721,8 @@ ExtText::ApproxWithLines( double dLinTol, double dAngTolDeg, POLYLINELIST& lstPL
bool
ExtText::Flip( void)
{
// imposto ricalcolo della grafica
m_OGrMgr.Reset() ;
// recupero il centro
Point3d ptCen ;
if ( ! GetCenterPoint( ptCen))
@@ -736,6 +738,8 @@ ExtText::Flip( void)
bool
ExtText::Mir( bool bOnLen)
{
// imposto ricalcolo della grafica
m_OGrMgr.Reset() ;
// imposto il font corrente e i suoi dati
FontManager& fntMgr = FontManager::GetFontManager() ;
if ( ! fntMgr.SetCurrFont( m_sFont, m_nWeight, m_bItalic, m_dHeight, m_dRatio, m_dAddAdvance))
@@ -771,5 +775,33 @@ ExtText::Mir( bool bOnLen)
m_vtN *= - 1 ;
}
return true ;
}
//----------------------------------------------------------------------------
bool
ExtText::ModifyText( const string& sText)
{
// verifico che il testo sia valido
if ( sText.empty())
return false ;
// imposto ricalcolo della grafica
m_OGrMgr.Reset() ;
// assegno nuovo test
m_sText = sText ;
return true ;
}
//----------------------------------------------------------------------------
bool
ExtText::ChangeFont( const string& sFont)
{
// imposto ricalcolo della grafica
m_OGrMgr.Reset() ;
// assegno nuovo font
m_sFont = sFont ;
return true ;
}