fdo#82577: Handle Font

Put the VCL Font class in the vcl namespace. Avoids clash with the X11
Font typedef.

Change-Id: I1a84f7cad8b31697b9860a3418f7dff794ff6537
This commit is contained in:
Noel Grandin 2014-09-16 10:09:58 +02:00
parent 9c81826876
commit 60e78fbb80
470 changed files with 1396 additions and 1392 deletions

View File

@ -40,7 +40,7 @@ private:
public:
CharacterAttributesHelper( const Font& rFont, sal_Int32 nBackColor, sal_Int32 nColor );
CharacterAttributesHelper( const vcl::Font& rFont, sal_Int32 nBackColor, sal_Int32 nColor );
~CharacterAttributesHelper();
::com::sun::star::uno::Sequence< ::com::sun::star::beans::PropertyValue > GetCharacterAttributes();

View File

@ -509,7 +509,7 @@ sal_Int32 SAL_CALL AccessibleBrowseBoxBase::getForeground( ) throw (::com::sun:
nColor = pInst->GetControlForeground().GetColor();
else
{
Font aFont;
vcl::Font aFont;
if ( pInst->IsControlFont() )
aFont = pInst->GetControlFont();
else

View File

@ -426,7 +426,7 @@ sal_Int32 SAL_CALL AccessibleGridControlBase::getForeground( ) throw (::com::su
nColor = pInst->GetControlForeground().GetColor();
else
{
Font aFont;
vcl::Font aFont;
if ( pInst->IsControlFont() )
aFont = pInst->GetControlFont();
else

View File

@ -444,7 +444,7 @@ namespace accessibility
nColor = m_pTabBar->GetControlForeground().GetColor();
else
{
Font aFont;
vcl::Font aFont;
if ( m_pTabBar->IsControlFont() )
aFont = m_pTabBar->GetControlFont();
else
@ -488,7 +488,7 @@ namespace accessibility
Reference< awt::XDevice > xDev( m_pTabBar->GetComponentInterface(), UNO_QUERY );
if ( xDev.is() )
{
Font aFont;
vcl::Font aFont;
if ( m_pTabBar->IsControlFont() )
aFont = m_pTabBar->GetControlFont();
else

View File

@ -997,7 +997,7 @@ Document::retrieveCharacterAttributes(
{
::osl::Guard< ::comphelper::IMutex > aExternalGuard(getExternalLock());
Font aFont = m_rEngine.GetFont();
vcl::Font aFont = m_rEngine.GetFont();
const sal_Int32 AttributeCount = 9;
sal_Int32 i = 0;
css::uno::Sequence< css::beans::PropertyValue > aAttribs( AttributeCount );

View File

@ -24,7 +24,7 @@ using namespace ::com::sun::star::uno;
using namespace ::com::sun::star::beans;
CharacterAttributesHelper::CharacterAttributesHelper( const Font& rFont, sal_Int32 nBackColor, sal_Int32 nColor )
CharacterAttributesHelper::CharacterAttributesHelper( const vcl::Font& rFont, sal_Int32 nBackColor, sal_Int32 nColor )
{
m_aAttributeMap.insert( AttributeMap::value_type( OUString( "CharBackColor" ), makeAny( (sal_Int32) nBackColor ) ) );
m_aAttributeMap.insert( AttributeMap::value_type( OUString( "CharColor" ), makeAny( (sal_Int32) nColor ) ) );

View File

@ -242,7 +242,7 @@ Sequence< PropertyValue > VCLXAccessibleMenuItem::getCharacterAttributes( sal_In
if ( !implIsValidIndex( nIndex, sText.getLength() ) )
throw IndexOutOfBoundsException();
Font aFont = Application::GetSettings().GetStyleSettings().GetMenuFont();
vcl::Font aFont = Application::GetSettings().GetStyleSettings().GetMenuFont();
sal_Int32 nBackColor = getBackground();
sal_Int32 nColor = getForeground();
return CharacterAttributesHelper( aFont, nBackColor, nColor )

View File

@ -511,7 +511,7 @@ Sequence< PropertyValue > VCLXAccessibleStatusBarItem::getCharacterAttributes( s
if ( m_pStatusBar )
{
Font aFont = m_pStatusBar->GetFont();
vcl::Font aFont = m_pStatusBar->GetFont();
sal_Int32 nBackColor = getBackground();
sal_Int32 nColor = getForeground();
aValues = CharacterAttributesHelper( aFont, nBackColor, nColor )

View File

@ -585,7 +585,7 @@ Sequence< PropertyValue > VCLXAccessibleTabPage::getCharacterAttributes( sal_Int
if ( m_pTabControl )
{
Font aFont = m_pTabControl->GetFont();
vcl::Font aFont = m_pTabControl->GetFont();
sal_Int32 nBackColor = getBackground();
sal_Int32 nColor = getForeground();
aValues = CharacterAttributesHelper( aFont, nBackColor, nColor )

View File

@ -183,7 +183,7 @@ Sequence< PropertyValue > VCLXAccessibleTextComponent::getCharacterAttributes( s
if ( GetWindow() )
{
Font aFont = GetWindow()->GetControlFont();
vcl::Font aFont = GetWindow()->GetControlFont();
sal_Int32 nBackColor = GetWindow()->GetControlBackground().GetColor();
sal_Int32 nColor = GetWindow()->GetControlForeground().GetColor();

View File

@ -502,7 +502,7 @@ sal_Int32 AccessibleDialogControlShape::getForeground( ) throw (RuntimeExceptio
nColor = pWindow->GetControlForeground().GetColor();
else
{
Font aFont;
vcl::Font aFont;
if ( pWindow->IsControlFont() )
aFont = pWindow->GetControlFont();
else
@ -548,7 +548,7 @@ Reference< awt::XFont > AccessibleDialogControlShape::getFont( ) throw (Runtime
Reference< awt::XDevice > xDev( pWindow->GetComponentInterface(), UNO_QUERY );
if ( xDev.is() )
{
Font aFont;
vcl::Font aFont;
if ( pWindow->IsControlFont() )
aFont = pWindow->GetControlFont();
else

View File

@ -832,7 +832,7 @@ sal_Int32 AccessibleDialogWindow::getForeground( ) throw (RuntimeException, std
nColor = m_pDialogWindow->GetControlForeground().GetColor();
else
{
Font aFont;
vcl::Font aFont;
if ( m_pDialogWindow->IsControlFont() )
aFont = m_pDialogWindow->GetControlFont();
else
@ -876,7 +876,7 @@ Reference< awt::XFont > AccessibleDialogWindow::getFont( ) throw (RuntimeExcept
Reference< awt::XDevice > xDev( m_pDialogWindow->GetComponentInterface(), UNO_QUERY );
if ( xDev.is() )
{
Font aFont;
vcl::Font aFont;
if ( m_pDialogWindow->IsControlFont() )
aFont = m_pDialogWindow->GetControlFont();
else

View File

@ -104,12 +104,12 @@ void lcl_PrintHeader( Printer* pPrinter, sal_uInt16 nPages, sal_uInt16 nCurPage,
const Color aOldLineColor( pPrinter->GetLineColor() );
const Color aOldFillColor( pPrinter->GetFillColor() );
const Font aOldFont( pPrinter->GetFont() );
const vcl::Font aOldFont( pPrinter->GetFont() );
pPrinter->SetLineColor( Color( COL_BLACK ) );
pPrinter->SetFillColor();
Font aFont( aOldFont );
vcl::Font aFont( aOldFont );
aFont.SetWeight( WEIGHT_BOLD );
aFont.SetAlign( ALIGN_BOTTOM );
pPrinter->SetFont( aFont );
@ -839,9 +839,9 @@ sal_Int32 ModulWindow::FormatAndPrint( Printer* pPrinter, sal_Int32 nPrintPage )
AssertValidEditEngine();
MapMode eOldMapMode( pPrinter->GetMapMode() );
Font aOldFont( pPrinter->GetFont() );
vcl::Font aOldFont( pPrinter->GetFont() );
Font aFont( GetEditEngine()->GetFont() );
vcl::Font aFont( GetEditEngine()->GetFont() );
aFont.SetAlign( ALIGN_BOTTOM );
aFont.SetTransparent( true );
aFont.SetSize( Size( 0, 360 ) );

View File

@ -1052,7 +1052,7 @@ void EditorWindow::DataChanged(DataChangedEvent const & rDCEvt)
if (!pOldSettings || aColor !=
pOldSettings-> GetStyleSettings().GetFieldTextColor())
{
Font aFont(pEditEngine->GetFont());
vcl::Font aFont(pEditEngine->GetFont());
aFont.SetColor(aColor);
pEditEngine->SetFont(aFont);
}
@ -1220,11 +1220,11 @@ void EditorWindow::ImplSetFont()
get_value_or( OUString() ) );
if ( sFontName.isEmpty() )
{
Font aTmpFont( OutputDevice::GetDefaultFont( DEFAULTFONT_FIXED, Application::GetSettings().GetUILanguageTag().getLanguageType(), 0 , this ) );
vcl::Font aTmpFont( OutputDevice::GetDefaultFont( DEFAULTFONT_FIXED, Application::GetSettings().GetUILanguageTag().getLanguageType(), 0 , this ) );
sFontName = aTmpFont.GetName();
}
Size aFontSize(0, officecfg::Office::Common::Font::SourceViewFont::FontHeight::get());
Font aFont( sFontName, aFontSize );
vcl::Font aFont( sFontName, aFontSize );
aFont.SetColor( GetSettings().GetStyleSettings().GetFieldTextColor() );
SetPointFont( aFont );
aFont = GetFont();

View File

@ -1371,7 +1371,7 @@ void DialogWindow::InitSettings(bool bFont, bool bForeground, bool bBackground)
const StyleSettings& rStyleSettings = GetSettings().GetStyleSettings();
if( bFont )
{
Font aFont;
vcl::Font aFont;
aFont = rStyleSettings.GetFieldFont();
SetPointFont( aFont );
}

View File

@ -44,7 +44,7 @@ Layout::Layout (Window* pParent) :
{
SetBackground(GetSettings().GetStyleSettings().GetWindowColor());
Font aFont = GetFont();
vcl::Font aFont = GetFont();
Size aSz = aFont.GetSize();
aSz.Height() *= 1.5;
aFont.SetSize(aSz);
@ -145,7 +145,7 @@ void Layout::DataChanged (DataChangedEvent const& rDCEvt)
aColor = GetSettings().GetStyleSettings().GetWindowTextColor();
if (!pOldSettings || aColor != pOldSettings->GetStyleSettings().GetWindowTextColor())
{
Font aFont(GetFont());
vcl::Font aFont(GetFont());
aFont.SetColor(aColor);
SetFont(aFont);
bInvalidate = true;

View File

@ -1125,7 +1125,7 @@ void lcl_PrintHeader( Printer* pPrinter, const OUString& rTitle ) // not working
pPrinter->SetLineColor( COL_BLACK );
pPrinter->SetFillColor();
Font aFont( pPrinter->GetFont() );
vcl::Font aFont( pPrinter->GetFont() );
aFont.SetWeight( WEIGHT_BOLD );
aFont.SetAlign( ALIGN_BOTTOM );
pPrinter->SetFont( aFont );
@ -1170,11 +1170,11 @@ void DlgEditor::Print( Printer* pPrinter, const OUString& rTitle ) // not wor
{
{
MapMode aOldMap( pPrinter->GetMapMode());
Font aOldFont( pPrinter->GetFont() );
vcl::Font aOldFont( pPrinter->GetFont() );
MapMode aMap( MAP_100TH_MM );
pPrinter->SetMapMode( aMap );
Font aFont;
vcl::Font aFont;
aFont.SetAlign( ALIGN_BOTTOM );
aFont.SetSize( Size( 0, 360 ));
pPrinter->SetFont( aFont );

View File

@ -67,7 +67,7 @@ SvRTLInputBox::SvRTLInputBox( Window* pParent, const OUString& rPrompt,
aEdit.Show();
aPromptText.Show();
SetText( rTitle );
Font aFont( GetFont());
vcl::Font aFont( GetFont());
Color aColor( GetBackground().GetColor() );
aFont.SetFillColor( aColor );
aEdit.SetFont( aFont );

View File

@ -41,7 +41,7 @@ namespace cairocanvas
const geometry::Matrix2D& rFontMatrix,
const SurfaceProviderRef& rDevice ) :
CanvasFont_Base( m_aMutex ),
maFont( Font( rFontRequest.FontDescription.FamilyName,
maFont( vcl::Font( rFontRequest.FontDescription.FamilyName,
rFontRequest.FontDescription.StyleName,
Size( 0, ::basegfx::fround(rFontRequest.CellSize) ) ) ),
maFontRequest( rFontRequest ),
@ -157,7 +157,7 @@ namespace cairocanvas
return aRet;
}
::Font CanvasFont::getVCLFont() const
vcl::Font CanvasFont::getVCLFont() const
{
return *maFont;
}

View File

@ -71,10 +71,10 @@ namespace cairocanvas
virtual sal_Bool SAL_CALL supportsService( const OUString& ServiceName ) throw( ::com::sun::star::uno::RuntimeException, std::exception ) SAL_OVERRIDE;
virtual ::com::sun::star::uno::Sequence< OUString > SAL_CALL getSupportedServiceNames() throw( ::com::sun::star::uno::RuntimeException, std::exception ) SAL_OVERRIDE;
::Font getVCLFont() const;
vcl::Font getVCLFont() const;
private:
::canvas::vcltools::VCLObject<Font> maFont;
::canvas::vcltools::VCLObject<vcl::Font> maFont;
::com::sun::star::rendering::FontRequest maFontRequest;
SurfaceProviderRef mpRefDevice;
};

View File

@ -61,7 +61,7 @@ namespace cairocanvas
static bool
setupFontTransform( ::OutputDevice& rOutDev,
::Point& o_rPoint,
::Font& io_rVCLFont,
vcl::Font& io_rVCLFont,
const rendering::ViewState& rViewState,
const rendering::RenderState& rRenderState )
{
@ -247,7 +247,7 @@ namespace cairocanvas
{
setupOutDevState( rOutDev, pOwner, viewState, renderState, TEXT_COLOR );
::Font aVCLFont;
vcl::Font aVCLFont;
CanvasFont* pFont = dynamic_cast< CanvasFont* >( xFont.get() );

View File

@ -510,7 +510,7 @@ namespace cairocanvas
// Font rotation and scaling
cairo_matrix_t m;
Font aFont = rOutDev.GetFont();
vcl::Font aFont = rOutDev.GetFont();
cairo_matrix_init_identity(&m);

View File

@ -111,7 +111,7 @@ namespace dxcanvas
// create the font
const ::com::sun::star::rendering::FontRequest& rFontRequest = rCanvasFont->getFontRequest();
Font aFont(
vcl::Font aFont(
rFontRequest.FontDescription.FamilyName,
rFontRequest.FontDescription.StyleName,
Size( 0, ::basegfx::fround(rFontRequest.CellSize)));

View File

@ -735,7 +735,7 @@ namespace oglcanvas
// create the font
const rendering::FontRequest& rFontRequest = pFont->getFontRequest();
const geometry::Matrix2D& rFontMatrix = pFont->getFontMatrix();
::Font aFont(
vcl::Font aFont(
rFontRequest.FontDescription.FamilyName,
rFontRequest.FontDescription.StyleName,
Size( 0, ::basegfx::fround(rFontRequest.CellSize)));

View File

@ -42,7 +42,7 @@ namespace vclcanvas
rendering::XGraphicDevice& rDevice,
const OutDevProviderSharedPtr& rOutDevProvider ) :
CanvasFont_Base( m_aMutex ),
maFont( Font( rFontRequest.FontDescription.FamilyName,
maFont( vcl::Font( rFontRequest.FontDescription.FamilyName,
rFontRequest.FontDescription.StyleName,
Size( 0, ::basegfx::fround(rFontRequest.CellSize) ) ) ),
maFontRequest( rFontRequest ),
@ -169,7 +169,7 @@ namespace vclcanvas
return aRet;
}
::Font CanvasFont::getVCLFont() const
vcl::Font CanvasFont::getVCLFont() const
{
return *maFont;
}

View File

@ -74,10 +74,10 @@ namespace vclcanvas
virtual sal_Bool SAL_CALL supportsService( const OUString& ServiceName ) throw( ::com::sun::star::uno::RuntimeException, std::exception ) SAL_OVERRIDE;
virtual ::com::sun::star::uno::Sequence< OUString > SAL_CALL getSupportedServiceNames() throw( ::com::sun::star::uno::RuntimeException, std::exception ) SAL_OVERRIDE;
::Font getVCLFont() const;
vcl::Font getVCLFont() const;
private:
::canvas::vcltools::VCLObject<Font> maFont;
::canvas::vcltools::VCLObject<vcl::Font> maFont;
::com::sun::star::rendering::FontRequest maFontRequest;
::com::sun::star::uno::Reference< ::com::sun::star::rendering::XGraphicDevice> mpRefDevice;
OutDevProviderSharedPtr mpOutDevProvider;

View File

@ -1369,7 +1369,7 @@ namespace vclcanvas
OutputDevice& rOutDev( mpOutDev->getOutDev() );
::Font aVCLFont;
vcl::Font aVCLFont;
CanvasFont* pFont = dynamic_cast< CanvasFont* >( xFont.get() );

View File

@ -100,7 +100,7 @@ namespace vclcanvas
}
bool setupFontTransform( ::Point& o_rPoint,
::Font& io_rVCLFont,
vcl::Font& io_rVCLFont,
const rendering::ViewState& rViewState,
const rendering::RenderState& rRenderState,
::OutputDevice& rOutDev )

View File

@ -85,11 +85,11 @@ namespace vclcanvas
@returns false, if no text output should happen
*/
bool setupFontTransform( ::Point& o_rPoint,
::Font& io_rVCLFont,
bool setupFontTransform( ::Point& o_rPoint,
vcl::Font& io_rVCLFont,
const ::com::sun::star::rendering::ViewState& viewState,
const ::com::sun::star::rendering::RenderState& renderState,
::OutputDevice& rOutDev );
::OutputDevice& rOutDev );
/** Predicate, to determine whether polygon is actually an axis-aligned rectangle

View File

@ -161,7 +161,7 @@ namespace vclcanvas
const OUString& rStr,
const Point& rPos )
{
Font aVCLFont;
vcl::Font aVCLFont;
aVCLFont.SetHeight( 20 );
aVCLFont.SetColor( Color( INFO_COLOR ) );

View File

@ -319,7 +319,7 @@ namespace vclcanvas
}
// paint sprite prio
Font aVCLFont;
vcl::Font aVCLFont;
aVCLFont.SetHeight( std::min(long(20),aOutputSize.Height()) );
aVCLFont.SetColor( COL_RED );

View File

@ -247,7 +247,7 @@ DataSourceTabPage::DataSourceTabPage(
// set symbol font for arrows
// note: StarSymbol is substituted to OpenSymbol for OOo
Font aSymbolFont( m_pBTN_UP->GetFont());
vcl::Font aSymbolFont( m_pBTN_UP->GetFont());
aSymbolFont.SetName( "StarSymbol" );
m_pBTN_UP->SetControlFont( aSymbolFont );
m_pBTN_DOWN->SetControlFont( aSymbolFont );

View File

@ -166,7 +166,7 @@ void ChartController::executeDispatch_InsertSpecialCharacter()
//set fixed current font
aSet.Put( SfxBoolItem( FN_PARAM_2, true ) ); //maybe not necessary in future
Font aCurFont = m_pDrawViewWrapper->getOutliner()->GetRefDevice()->GetFont();
vcl::Font aCurFont = m_pDrawViewWrapper->getOutliner()->GetRefDevice()->GetFont();
aSet.Put( SvxFontItem( aCurFont.GetFamily(), aCurFont.GetName(), aCurFont.GetStyleName(), aCurFont.GetPitch(), aCurFont.GetCharSet(), SID_ATTR_CHAR_FONT ) );
boost::scoped_ptr<SfxAbstractDialog> pDlg(pFact->CreateSfxDialog( m_pChartWindow, aSet, getFrame(), RID_SVXDLG_CHARMAP ));

View File

@ -407,11 +407,11 @@ void CharacterProperties::AddDefaultsToMap(
using namespace ::com::sun::star::i18n::ScriptType;
LanguageType nLang;
nLang = MsLangId::resolveSystemLanguageByScriptType(LanguageTag::convertToLanguageType( aDefaultLocale, false), LATIN);
Font aFont = OutputDevice::GetDefaultFont( DEFAULTFONT_LATIN_SPREADSHEET, nLang, DEFAULTFONT_FLAGS_ONLYONE, 0 );
vcl::Font aFont = OutputDevice::GetDefaultFont( DEFAULTFONT_LATIN_SPREADSHEET, nLang, DEFAULTFONT_FLAGS_ONLYONE, 0 );
nLang = MsLangId::resolveSystemLanguageByScriptType(LanguageTag::convertToLanguageType( aDefaultLocale_CJK, false), ASIAN);
Font aFontCJK = OutputDevice::GetDefaultFont( DEFAULTFONT_CJK_SPREADSHEET, nLang, DEFAULTFONT_FLAGS_ONLYONE, 0 );
vcl::Font aFontCJK = OutputDevice::GetDefaultFont( DEFAULTFONT_CJK_SPREADSHEET, nLang, DEFAULTFONT_FLAGS_ONLYONE, 0 );
nLang = MsLangId::resolveSystemLanguageByScriptType(LanguageTag::convertToLanguageType( aDefaultLocale_CTL, false), COMPLEX);
Font aFontCTL = OutputDevice::GetDefaultFont( DEFAULTFONT_CTL_SPREADSHEET, nLang, DEFAULTFONT_FLAGS_ONLYONE, 0 );
vcl::Font aFontCTL = OutputDevice::GetDefaultFont( DEFAULTFONT_CTL_SPREADSHEET, nLang, DEFAULTFONT_FLAGS_ONLYONE, 0 );
::chart::PropertyHelper::setPropertyValueDefault( rOutMap, PROP_CHAR_FONT_NAME, OUString( aFont.GetName() ) );
::chart::PropertyHelper::setPropertyValueDefault( rOutMap, PROP_CHAR_FONT_STYLE_NAME, OUString(aFont.GetStyleName()) );

View File

@ -77,7 +77,7 @@ const TextCacheItem& TextCache::getText(OUString const & rText)
return *itr->second;
VirtualDevice aDevice(*Application::GetDefaultDevice(), 0, 0);
Font aFont = aDevice.GetFont();
vcl::Font aFont = aDevice.GetFont();
aFont.SetSize(Size(0, 96));
static bool bOldRender = getenv("OLDRENDER");
if (bOldRender)

View File

@ -767,7 +767,7 @@ namespace {
struct FontAttribSetter
{
FontAttribSetter(Font& rFont):
FontAttribSetter(vcl::Font& rFont):
mrFont(rFont) {}
void operator()(const std::pair<OUString, uno::Any>& rProp)
@ -807,7 +807,7 @@ struct FontAttribSetter
}
}
private:
Font& mrFont;
vcl::Font& mrFont;
};
}
@ -836,7 +836,7 @@ DummyText::DummyText(const OUString& rText, const tNameSequence& rNames,
}
else
{
Font aFont;
vcl::Font aFont;
std::for_each(maProperties.begin(), maProperties.end(), FontAttribSetter(aFont));
VirtualDevice aDevice(*Application::GetDefaultDevice(), 0, 0);
aDevice.Erase();

View File

@ -633,7 +633,7 @@ int OpenGLRender::RenderRectangleShape(bool bBorder, bool bFill)
return 0;
}
int OpenGLRender::CreateTextTexture(::rtl::OUString const &textValue, Font aFont, long , awt::Point aPos, awt::Size aSize, long rotation)
int OpenGLRender::CreateTextTexture(::rtl::OUString const &textValue, vcl::Font aFont, long , awt::Point aPos, awt::Size aSize, long rotation)
{
VirtualDevice aDevice(*Application::GetDefaultDevice(), 0, 0);
aDevice.Erase();

View File

@ -95,7 +95,7 @@ public:
int CreateTextTexture(const BitmapEx& rBitmapEx,
const css::awt::Point& aPos, const css::awt::Size& aSize,
long rotation, const css::drawing::HomogenMatrix3& rTrans);
int CreateTextTexture(::rtl::OUString const &textValue, Font aFont, long fontColor, css::awt::Point aPos, css::awt::Size aSize, long rotation);
int CreateTextTexture(::rtl::OUString const &textValue, vcl::Font aFont, long fontColor, css::awt::Point aPos, css::awt::Size aSize, long rotation);
int RenderTextShape();
int SetArea2DShapePoint(float x, float y, int listLength);

View File

@ -37,7 +37,7 @@ class GDIMetaFile;
class VirtualDevice;
class Gradient;
class Rectangle;
class Font;
namespace vcl { class Font; }
class PolyPolygon;
class Point;
class MetaCommentAction;
@ -242,7 +242,7 @@ static float GetSwapFloat( SvStream& rSt )
::com::sun::star::uno::Reference<
::com::sun::star::rendering::XCanvasFont > createFont( double& o_rFontRotation,
const ::Font& rFont,
const ::vcl::Font& rFont,
const ActionFactoryParameters& rParms ) const;
bool createActions( GDIMetaFile& rMtf,
const ActionFactoryParameters& rParms,

View File

@ -753,7 +753,7 @@ namespace cppcanvas
}
uno::Reference< rendering::XCanvasFont > ImplRenderer::createFont( double& o_rFontRotation,
const ::Font& rFont,
const vcl::Font& rFont,
const ActionFactoryParameters& rParms ) const
{
rendering::FontRequest aFontRequest;
@ -824,7 +824,7 @@ namespace cppcanvas
const sal_Int32 nFontWidthLog = rFontSizeLog.Width();
if( nFontWidthLog != 0 )
{
::Font aTestFont = rFont;
vcl::Font aTestFont = rFont;
aTestFont.SetWidth( 0 );
sal_Int32 nNormalWidth = rParms.mrVDev.GetFontMetric( aTestFont ).GetWidth();
if( nNormalWidth != nFontWidthLog )
@ -1488,7 +1488,7 @@ namespace cppcanvas
case META_FONT_ACTION:
{
::cppcanvas::internal::OutDevState& rState = rStates.getState();
const ::Font& rFont( static_cast<MetaFontAction*>(pCurrAct)->GetFont() );
const vcl::Font& rFont( static_cast<MetaFontAction*>(pCurrAct)->GetFont() );
rState.xFont = createFont( rState.fontRotation,
rFont,
@ -2985,7 +2985,7 @@ namespace cppcanvas
::cppcanvas::internal::OutDevState& rState = aStateStack.getState();
rState.xFont = createFont( rState.fontRotation,
::Font(), // default font
::vcl::Font(), // default font
aParms );
}

View File

@ -1954,8 +1954,8 @@ namespace cppcanvas
// (which is already contained in the render state
// transformation matrix - otherwise, glyph polygons
// will be rotated twice)
const ::Font aOrigFont( rVDev.GetFont() );
::Font aUnrotatedFont( aOrigFont );
const vcl::Font aOrigFont( rVDev.GetFont() );
vcl::Font aUnrotatedFont( aOrigFont );
aUnrotatedFont.SetOrientation(0);
rVDev.SetFont( aUnrotatedFont );

View File

@ -47,7 +47,7 @@ SpellErrorAttrib::~SpellErrorAttrib()
}
void SpellErrorAttrib::SetFont( Font& ) const
void SpellErrorAttrib::SetFont( vcl::Font& ) const
{
//this attribute doesn't have a visual effect
}
@ -85,7 +85,7 @@ SpellLanguageAttrib::~SpellLanguageAttrib()
}
void SpellLanguageAttrib::SetFont( Font& ) const
void SpellLanguageAttrib::SetFont( vcl::Font& ) const
{
//no visual effect
}
@ -123,7 +123,7 @@ SpellBackgroundAttrib::~SpellBackgroundAttrib()
}
void SpellBackgroundAttrib::SetFont( Font& rFont ) const
void SpellBackgroundAttrib::SetFont( vcl::Font& rFont ) const
{
rFont.SetFillColor(m_aBackgroundColor);
}

View File

@ -112,7 +112,7 @@ public:
const SpellErrorDescription& GetErrorDescription() const { return m_aSpellErrorDescription; }
virtual void SetFont( Font& rFont ) const SAL_OVERRIDE;
virtual void SetFont( vcl::Font& rFont ) const SAL_OVERRIDE;
virtual TextAttrib* Clone() const SAL_OVERRIDE;
virtual bool operator==( const TextAttrib& rAttr ) const SAL_OVERRIDE;
};
@ -135,7 +135,7 @@ public:
{m_eLanguage = eLang;}
virtual void SetFont( Font& rFont ) const SAL_OVERRIDE;
virtual void SetFont( vcl::Font& rFont ) const SAL_OVERRIDE;
virtual TextAttrib* Clone() const SAL_OVERRIDE;
virtual bool operator==( const TextAttrib& rAttr ) const SAL_OVERRIDE;
};
@ -157,7 +157,7 @@ public:
void SetColor( const Color& rNewCol ){m_aBackgroundColor = rNewCol;}
virtual void SetFont( Font& rFont ) const SAL_OVERRIDE;
virtual void SetFont( vcl::Font& rFont ) const SAL_OVERRIDE;
virtual TextAttrib* Clone() const SAL_OVERRIDE;
virtual bool operator==( const TextAttrib& rAttr ) const SAL_OVERRIDE;
};

View File

@ -144,8 +144,8 @@ void AboutDialog::StyleControls()
m_pDescriptionText->SetPaintTransparent(true);
m_pCopyrightText->SetPaintTransparent(true);
Font aLabelFont = GetSettings().GetStyleSettings().GetLabelFont();
Font aLargeFont = aLabelFont;
vcl::Font aLabelFont = GetSettings().GetStyleSettings().GetLabelFont();
vcl::Font aLargeFont = aLabelFont;
aLargeFont.SetSize( Size( 0, aLabelFont.GetSize().Height() * 3 ) );
// Logo Replacement Text

View File

@ -88,14 +88,14 @@ SvxCharacterMap::SvxCharacterMap( Window* pParent, bool bOne_, const SfxItemSet*
SFX_ITEMSET_ARG( pSet, pFontNameItem, SfxStringItem, SID_FONT_NAME, false );
if ( pFontItem )
{
Font aTmpFont( pFontItem->GetFamilyName(), pFontItem->GetStyleName(), GetCharFont().GetSize() );
vcl::Font aTmpFont( pFontItem->GetFamilyName(), pFontItem->GetStyleName(), GetCharFont().GetSize() );
aTmpFont.SetCharSet( pFontItem->GetCharSet() );
aTmpFont.SetPitch( pFontItem->GetPitch() );
SetCharFont( aTmpFont );
}
else if ( pFontNameItem )
{
Font aTmpFont( GetCharFont() );
vcl::Font aTmpFont( GetCharFont() );
aTmpFont.SetName( pFontNameItem->GetValue() );
SetCharFont( aTmpFont );
}
@ -151,7 +151,7 @@ short SvxCharacterMap::Execute()
if ( pSet )
{
const SfxItemPool* pPool = pSet->GetPool();
const Font& rFont( GetCharFont() );
const vcl::Font& rFont( GetCharFont() );
pSet->Put( SfxStringItem( pPool->GetWhich(SID_CHARMAP), GetCharacters() ) );
pSet->Put( SvxFontItem( rFont.GetFamily(), rFont.GetName(),
rFont.GetStyleName(), rFont.GetPitch(), rFont.GetCharSet(), pPool->GetWhich(SID_ATTR_CHAR_FONT) ) );
@ -195,7 +195,7 @@ void SvxShowText::Paint( const Rectangle& )
bool bGotBoundary = true;
bool bShrankFont = false;
Font aOrigFont(GetFont());
vcl::Font aOrigFont(GetFont());
Size aFontSize(aOrigFont.GetSize());
Rectangle aBoundRect;
@ -212,7 +212,7 @@ void SvxShowText::Paint( const Rectangle& )
long nTextWidth = aBoundRect.GetWidth();
if (nAvailWidth > nTextWidth)
break;
Font aFont(aOrigFont);
vcl::Font aFont(aOrigFont);
aFontSize.Height() = nFontHeight;
aFont.SetSize(aFontSize);
Control::SetFont(aFont);
@ -263,10 +263,10 @@ void SvxShowText::Paint( const Rectangle& )
void SvxShowText::SetFont( const Font& rFont )
void SvxShowText::SetFont( const vcl::Font& rFont )
{
long nWinHeight = GetOutputSizePixel().Height();
Font aFont = rFont;
vcl::Font aFont = rFont;
aFont.SetWeight( WEIGHT_NORMAL );
aFont.SetAlign( ALIGN_TOP );
aFont.SetSize( PixelToLogic( Size( 0, nWinHeight/2 ) ) );
@ -279,7 +279,7 @@ void SvxShowText::SetFont( const Font& rFont )
Size SvxShowText::GetOptimalSize() const
{
const Font &rFont = GetFont();
const vcl::Font &rFont = GetFont();
const Size rFontSize = rFont.GetSize();
long nWinHeight = LogicToPixel(rFontSize).Height() * 2;
return Size( GetTextWidth( GetText() ) + 2 * 12, nWinHeight );
@ -379,11 +379,11 @@ void SvxCharacterMap::init()
void SvxCharacterMap::SetCharFont( const Font& rFont )
void SvxCharacterMap::SetCharFont( const vcl::Font& rFont )
{
// first get the underlying info in order to get font names
// like "Times New Roman;Times" resolved
Font aTmp( GetFontMetric( rFont ) );
vcl::Font aTmp( GetFontMetric( rFont ) );
if ( m_pFontLB->GetEntryPos( aTmp.GetName() ) == LISTBOX_ENTRY_NOTFOUND )
return;

View File

@ -61,7 +61,7 @@ namespace svx
OutputDevice& m_rDev;
public:
inline FontSwitch( OutputDevice& _rDev, const Font& _rTemporaryFont )
inline FontSwitch( OutputDevice& _rDev, const vcl::Font& _rTemporaryFont )
:m_rDev( _rDev )
{
m_rDev.Push( PUSH_FONT );
@ -127,7 +127,7 @@ namespace svx
Size aPlaygroundSize( _rRect.GetSize() );
// the font for the secondary text:
Font aSmallerFont( _rDevice.GetFont() );
vcl::Font aSmallerFont( _rDevice.GetFont() );
// heuristic: 80% of the original size
aSmallerFont.SetHeight( (long)( 0.8 * aSmallerFont.GetHeight() ) );
@ -304,7 +304,7 @@ namespace svx
Size RubyRadioButton::GetOptimalSize() const
{
Font aSmallerFont( GetFont() );
vcl::Font aSmallerFont( GetFont() );
aSmallerFont.SetHeight( static_cast<long>( 0.8 * aSmallerFont.GetHeight() ) );
Rectangle rect( Point(), Size( SAL_MAX_INT32, SAL_MAX_INT32 ) );
sal_uInt16 style = GetStyle();

View File

@ -57,7 +57,7 @@ SvxPostItDialog::SvxPostItDialog(Window* pParent, const SfxItemSet& rCoreSet,
m_pAuthorBtn->SetClickHdl( LINK( this, SvxPostItDialog, Stamp ) );
m_pOKBtn->SetClickHdl( LINK( this, SvxPostItDialog, OKHdl ) );
Font aFont( m_pEditED->GetFont() );
vcl::Font aFont( m_pEditED->GetFont() );
aFont.SetWeight( WEIGHT_LIGHT );
m_pEditED->SetFont( aFont );

View File

@ -145,10 +145,10 @@ void AlternativesString::Paint(
{
AlternativesExtraData* pData = m_rControlImpl.GetExtraData( pEntry );
Point aPos( rPos );
Font aOldFont( rDev.GetFont());
vcl::Font aOldFont( rDev.GetFont());
if (pData && pData->IsHeader())
{
Font aFont( aOldFont );
vcl::Font aFont( aOldFont );
aFont.SetWeight( WEIGHT_BOLD );
rDev.SetFont( aFont );
aPos.X() = 0;

View File

@ -25,7 +25,7 @@
// caution: needs C-Linkage since dynamically loaded via symbol name
extern "C"
{
SAL_DLLPUBLIC_EXPORT bool GetSpecialCharsForEdit(Window* i_pParent, const Font& i_rFont, OUString& o_rResult)
SAL_DLLPUBLIC_EXPORT bool GetSpecialCharsForEdit(Window* i_pParent, const vcl::Font& i_rFont, OUString& o_rResult)
{
bool bRet = false;
boost::scoped_ptr<SvxCharacterMap> aDlg(new SvxCharacterMap( i_pParent ));

View File

@ -154,9 +154,9 @@ class OfaSwAutoFmtOptionsPage : public SfxTabPage
OUString sBulletChar;
OUString sByInputBulletChar;
Font aBulletFont;
Font aByInputBulletFont;
sal_uInt16 nPercent;
vcl::Font aBulletFont;
vcl::Font aByInputBulletFont;
sal_uInt16 nPercent;
SvLBoxButtonData* pCheckButtonData;

View File

@ -43,7 +43,7 @@ public:
bool bCenter = false );
virtual ~SvxShowText();
void SetFont( const Font& rFont );
void SetFont( const vcl::Font& rFont );
void SetText( const OUString& rText ) SAL_OVERRIDE;
void SetCentered(bool bCenter) { mbCenter = bCenter; }
@ -80,8 +80,8 @@ private:
FixedText* m_pSymbolText;
SvxShowText* m_pShowChar;
FixedText* m_pCharCodeText;
Font aFont;
bool bOne;
vcl::Font aFont;
bool bOne;
const SubsetMap* pSubsetMap;
DECL_LINK(OKHdl, void *);
@ -102,8 +102,8 @@ public:
void DisableFontSelection();
const Font& GetCharFont() const { return aFont;}
void SetCharFont( const Font& rFont );
const vcl::Font& GetCharFont() const { return aFont;}
void SetCharFont( const vcl::Font& rFont );
void SetChar( sal_UCS4 );
sal_UCS4 GetChar() const;

View File

@ -41,7 +41,7 @@ class SvxBrushItem;
class SvxNumberingPreview : public Window
{
const SvxNumRule* pActNum;
Font aStdFont;
vcl::Font aStdFont;
long nPageWidth;
const OUString* pOutlineNames;
bool bPosition;
@ -308,7 +308,7 @@ class SvxNumOptionsTabPage : public SfxTabPage
bool bMenuButtonInitialized : 1;
std::vector<OUString> aGrfNames;
Font aActBulletFont;
vcl::Font aActBulletFont;
sal_uInt8 nBullet;
sal_uInt16 nActNumLvl;

View File

@ -43,8 +43,8 @@ public:
void OptLBoxString_Impl::Paint(
const Point& rPos, SvTreeListBox& rDev, const SvViewDataEntry* /*pView*/, const SvTreeListEntry* pEntry)
{
Font aOldFont( rDev.GetFont() );
Font aFont( aOldFont );
vcl::Font aOldFont( rDev.GetFont() );
vcl::Font aFont( aOldFont );
//detect readonly state by asking for a valid Image
if(pEntry && !(!((OptHeaderTabListBox&)rDev).GetCollapsedEntryBmp(pEntry)))
aFont.SetColor( Application::GetSettings().GetStyleSettings().GetDeactiveTextColor() );

View File

@ -281,10 +281,10 @@ void BrwStringDic_Impl::Paint(
{
ModuleUserData_Impl* pData = (ModuleUserData_Impl*)pEntry->GetUserData();
Point aPos(rPos);
Font aOldFont( rDev.GetFont());
vcl::Font aOldFont( rDev.GetFont());
if(pData->IsParent())
{
Font aFont( aOldFont );
vcl::Font aFont( aOldFont );
aFont.SetWeight( WEIGHT_BOLD );
rDev.SetFont( aFont );
aPos.X() = 0;
@ -455,8 +455,8 @@ void BrwString_Impl::Paint(
{
Point aNewPos(aPos);
aNewPos.X() += rDev.GetTextWidth(GetText());
Font aOldFont( rDev.GetFont());
Font aFont( aOldFont );
vcl::Font aOldFont( rDev.GetFont());
vcl::Font aFont( aOldFont );
aFont.SetWeight( WEIGHT_BOLD );
//??? convert the lower byte from the user date into a string

View File

@ -268,9 +268,9 @@ void OfaAutocorrOptionsPage::Reset( const SfxItemSet* )
struct ImpUserData
{
OUString *pString;
Font *pFont;
vcl::Font *pFont;
ImpUserData(OUString* pText, Font* pFnt)
ImpUserData(OUString* pText, vcl::Font* pFnt)
{ pString = pText; pFont = pFnt;}
};
@ -324,8 +324,8 @@ void OfaImpBrwString::Paint(
ImpUserData* pUserData = (ImpUserData* )pEntry->GetUserData();
Point aNewPos(rPos);
aNewPos.X() += rDev.GetTextWidth(GetText());
Font aOldFont( rDev.GetFont());
Font aFont( aOldFont );
vcl::Font aOldFont( rDev.GetFont());
vcl::Font aFont( aOldFont );
if(pUserData->pFont)
{
aFont = *pUserData->pFont;
@ -701,7 +701,7 @@ IMPL_LINK_NOARG(OfaSwAutoFmtOptionsPage, EditHdl)
pMapDlg->SetChar( (*pUserData->pString)[0] );
if(RET_OK == pMapDlg->Execute())
{
Font aFont(pMapDlg->GetCharFont());
vcl::Font aFont(pMapDlg->GetCharFont());
*pUserData->pFont = aFont;
sal_UCS4 aChar = pMapDlg->GetChar();
// using the UCS4 constructor

View File

@ -81,7 +81,7 @@ SvxNumberPreview::SvxNumberPreview(Window* pParent, WinBits nStyle)
, mnPos(-1)
, mnChar(0x0)
{
Font aFont( GetFont() );
vcl::Font aFont( GetFont() );
aFont.SetTransparent( true );
aFont.SetColor( Application::GetSettings().GetStyleSettings().GetFieldColor() );
SetFont( aFont );
@ -149,10 +149,10 @@ void SvxNumberPreview::NotifyChange( const OUString& rPrevStr,
void SvxNumberPreview::Paint( const Rectangle& )
{
Font aDrawFont = GetFont();
Size aSzWnd = GetOutputSizePixel();
OUString aTmpStr( aPrevStr );
long nLeadSpace = (aSzWnd.Width() - GetTextWidth( aTmpStr )) /2;
vcl::Font aDrawFont = GetFont();
Size aSzWnd = GetOutputSizePixel();
OUString aTmpStr( aPrevStr );
long nLeadSpace = (aSzWnd.Width() - GetTextWidth( aTmpStr )) /2;
aDrawFont.SetColor( aPrevCol );
SetFont( aDrawFont );
@ -830,7 +830,7 @@ void SvxNumberFormatTabPage::FillFormatListBox_Impl( std::vector<OUString>& rEnt
{
OUString aEntry;
OUString aTmpString;
Font aFont=m_pLbCategory->GetFont();
vcl::Font aFont=m_pLbCategory->GetFont();
size_t i = 0;
short nTmpCatPos;
short aPrivCat;
@ -877,7 +877,7 @@ void SvxNumberFormatTabPage::FillFormatListBox_Impl( std::vector<OUString>& rEnt
{
Color* pPreviewColor = NULL;
OUString aPreviewString( GetExpColorString( pPreviewColor, aEntry, aPrivCat ) );
Font aEntryFont( m_pLbFormat->GetFont() );
vcl::Font aEntryFont( m_pLbFormat->GetFont() );
m_pLbFormat->InsertFontEntry( aPreviewString, aEntryFont, pPreviewColor );
}
else

View File

@ -156,10 +156,10 @@ static bool lcl_IsNumFmtSet(SvxNumRule* pNum, sal_uInt16 nLevelMask)
return bRet;
}
static Font& lcl_GetDefaultBulletFont()
static vcl::Font& lcl_GetDefaultBulletFont()
{
static bool bInit = false;
static Font aDefBulletFont( OUString("StarSymbol"),
static vcl::Font aDefBulletFont( OUString("StarSymbol"),
OUString(), Size( 0, 14 ) );
if(!bInit)
{
@ -476,7 +476,7 @@ IMPL_LINK_NOARG(SvxBulletPickTabPage, NumSelectHdl_Impl)
bPreset = false;
bModified = true;
sal_Unicode cChar = aBulletTypes[m_pExamplesVS->GetSelectItemId() - 1];
Font& rActBulletFont = lcl_GetDefaultBulletFont();
vcl::Font& rActBulletFont = lcl_GetDefaultBulletFont();
sal_uInt16 nMask = 1;
for(sal_uInt16 i = 0; i < pActNum->GetLevelCount(); i++)
@ -679,7 +679,7 @@ IMPL_LINK_NOARG(SvxNumPickTabPage, NumSelectHdl_Impl)
SvxNumSettingsArr_Impl& rItemArr = aNumSettingsArrays[m_pExamplesVS->GetSelectItemId() - 1];
Font& rActBulletFont = lcl_GetDefaultBulletFont();
vcl::Font& rActBulletFont = lcl_GetDefaultBulletFont();
SvxNumSettings_Impl* pLevelSettings = 0;
for(sal_uInt16 i = 0; i < pActNum->GetLevelCount(); i++)
{
@ -712,13 +712,13 @@ IMPL_LINK_NOARG(SvxNumPickTabPage, NumSelectHdl_Impl)
{
vcl::FontInfo aInfo = pList->Get(
pLevelSettings->sBulletFont,WEIGHT_NORMAL, ITALIC_NONE);
Font aFont(aInfo);
vcl::Font aFont(aInfo);
aFmt.SetBulletFont(&aFont);
}
else
{
//if it cannot be found then create a new one
Font aCreateFont( pLevelSettings->sBulletFont,
vcl::Font aCreateFont( pLevelSettings->sBulletFont,
OUString(), Size( 0, 14 ) );
aCreateFont.SetCharSet( RTL_TEXTENCODING_DONTKNOW );
aCreateFont.SetFamily( FAMILY_DONTKNOW );
@ -2009,7 +2009,7 @@ IMPL_LINK_NOARG(SvxNumOptionsTabPage, BulletHdl_Impl)
boost::scoped_ptr<SvxCharacterMap> pMap(new SvxCharacterMap( this, true ));
sal_uInt16 nMask = 1;
const Font* pFmtFont = 0;
const vcl::Font* pFmtFont = 0;
bool bSameBullet = true;
sal_Unicode cBullet = 0;
bool bFirst = true;
@ -2234,10 +2234,10 @@ static sal_uInt16 lcl_DrawBullet(VirtualDevice* pVDev,
const SvxNumberFormat& rFmt, sal_uInt16 nXStart,
sal_uInt16 nYStart, const Size& rSize)
{
Font aTmpFont(pVDev->GetFont());
vcl::Font aTmpFont(pVDev->GetFont());
// via Uno it's possible that no font has been set!
Font aFont(rFmt.GetBulletFont() ? *rFmt.GetBulletFont() : aTmpFont);
vcl::Font aFont(rFmt.GetBulletFont() ? *rFmt.GetBulletFont() : aTmpFont);
Size aTmpSize(rSize);
aTmpSize.Width() *= rFmt.GetBulletRelSize();
aTmpSize.Width() /= 100 ;
@ -2403,8 +2403,8 @@ void SvxNumberingPreview::Paint( const Rectangle& /*rRect*/ )
if(pActNum->IsContinuousNumbering())
aNum.GetLevelVal()[nLevel] = nPreNum;
OUString aText(pActNum->MakeNumString( aNum ));
Font aSaveFont = pVDev->GetFont();
Font aColorFont(aSaveFont);
vcl::Font aSaveFont = pVDev->GetFont();
vcl::Font aColorFont(aSaveFont);
Color aTmpBulletColor = rFmt.GetBulletColor();
if(aTmpBulletColor.GetColor() == COL_AUTO)
aTmpBulletColor = Color(aBackColor.IsDark() ? COL_WHITE : COL_BLACK);
@ -2526,7 +2526,7 @@ void SvxNumberingPreview::Paint( const Rectangle& /*rRect*/ )
}
else
{
Font aColorFont(aStdFont);
vcl::Font aColorFont(aStdFont);
Color aTmpBulletColor = rFmt.GetBulletColor();
if(aTmpBulletColor.GetColor() == COL_AUTO)
aTmpBulletColor = Color(aBackColor.IsDark() ? COL_WHITE : COL_BLACK);

View File

@ -167,7 +167,7 @@ namespace
const StyleSettings& rStyleSettings = GetSettings().GetStyleSettings();
if( bFont )
{
Font aFont;
vcl::Font aFont;
aFont = rStyleSettings.GetFieldFont();
aFont.SetColor( rStyleSettings.GetWindowTextColor() );
SetPointFont( aFont );
@ -1232,7 +1232,7 @@ void OAppDetailPageHelper::DataChanged( const DataChangedEvent& rDCEvt )
{
Window::DataChanged( rDCEvt );
if ( (rDCEvt.GetType() == DATACHANGED_FONTS) ||
if ( (rDCEvt.GetType() == DATACHANGED_FONTS) ||
(rDCEvt.GetType() == DATACHANGED_DISPLAY) ||
(rDCEvt.GetType() == DATACHANGED_FONTSUBSTITUTION) ||
((rDCEvt.GetType() == DATACHANGED_SETTINGS) &&
@ -1253,25 +1253,24 @@ void OAppDetailPageHelper::DataChanged( const DataChangedEvent& rDCEvt )
void OAppDetailPageHelper::ImplInitSettings()
{
const StyleSettings& rStyleSettings = GetSettings().GetStyleSettings();
Font aFont;
aFont = rStyleSettings.GetFieldFont();
aFont.SetColor( rStyleSettings.GetWindowTextColor() );
SetPointFont( aFont );
m_aTBPreview.SetPointFont( aFont );
vcl::Font aFont;
aFont = rStyleSettings.GetFieldFont();
aFont.SetColor( rStyleSettings.GetWindowTextColor() );
SetPointFont( aFont );
m_aTBPreview.SetPointFont( aFont );
SetTextColor( rStyleSettings.GetFieldTextColor() );
SetTextFillColor();
m_aBorder.SetTextColor( rStyleSettings.GetFieldTextColor() );
m_aBorder.SetTextFillColor();
m_aTBPreview.SetTextColor( rStyleSettings.GetFieldTextColor() );
m_aTBPreview.SetTextFillColor();
SetBackground( rStyleSettings.GetFieldColor() );
m_aBorder.SetBackground( rStyleSettings.GetFieldColor() );
m_aFL.SetBackground( rStyleSettings.GetFieldColor() );
m_aDocumentInfo.SetBackground( rStyleSettings.GetFieldColor() );
m_aTBPreview.SetBackground( rStyleSettings.GetFieldColor() );
m_pTablePreview->SetBackground( rStyleSettings.GetFieldColor() );
SetTextColor( rStyleSettings.GetFieldTextColor() );
SetTextFillColor();
m_aBorder.SetTextColor( rStyleSettings.GetFieldTextColor() );
m_aBorder.SetTextFillColor();
m_aTBPreview.SetTextColor( rStyleSettings.GetFieldTextColor() );
m_aTBPreview.SetTextFillColor();
SetBackground( rStyleSettings.GetFieldColor() );
m_aBorder.SetBackground( rStyleSettings.GetFieldColor() );
m_aFL.SetBackground( rStyleSettings.GetFieldColor() );
m_aDocumentInfo.SetBackground( rStyleSettings.GetFieldColor() );
m_aTBPreview.SetBackground( rStyleSettings.GetFieldColor() );
m_pTablePreview->SetBackground( rStyleSettings.GetFieldColor() );
}
OPreviewWindow::OPreviewWindow(Window* _pParent)
@ -1346,7 +1345,7 @@ void OPreviewWindow::ImplInitSettings( bool bFont, bool bForeground, bool bBackg
const StyleSettings& rStyleSettings = GetSettings().GetStyleSettings();
if( bFont )
{
Font aFont;
vcl::Font aFont;
aFont = rStyleSettings.GetFieldFont();
aFont.SetColor( rStyleSettings.GetWindowTextColor() );
SetPointFont( aFont );

View File

@ -111,7 +111,7 @@ void OCreationList::PreparePaint( SvTreeListEntry* _pEntry )
if ( bIsMouseDownEntry )
{
Font aFont( GetFont() );
vcl::Font aFont( GetFont() );
aFont.SetColor( GetSettings().GetStyleSettings().GetHighlightTextColor() );
Control::SetFont( aFont );
}
@ -384,7 +384,7 @@ void OTasksWindow::ImplInitSettings( bool bFont, bool bForeground, bool bBackgro
const StyleSettings& rStyleSettings = GetSettings().GetStyleSettings();
if( bFont )
{
Font aFont;
vcl::Font aFont;
aFont = rStyleSettings.GetFieldFont();
aFont.SetColor( rStyleSettings.GetWindowTextColor() );
SetPointFont( aFont );
@ -408,7 +408,7 @@ void OTasksWindow::ImplInitSettings( bool bFont, bool bForeground, bool bBackgro
m_aFL.SetBackground( rStyleSettings.GetFieldColor() );
}
Font aFont = m_aDescription.GetControlFont();
vcl::Font aFont = m_aDescription.GetControlFont();
aFont.SetWeight(WEIGHT_BOLD);
m_aDescription.SetControlFont(aFont);
}
@ -565,7 +565,7 @@ void OApplicationDetailView::ImplInitSettings( bool bFont, bool bForeground, boo
const StyleSettings& rStyleSettings = GetSettings().GetStyleSettings();
if( bFont )
{
Font aFont;
vcl::Font aFont;
aFont = rStyleSettings.GetFieldFont();
aFont.SetColor( rStyleSettings.GetWindowTextColor() );
SetPointFont( aFont );

View File

@ -51,8 +51,8 @@ namespace dbaui
// members related to drawing the currently hovered/selected entry
SvTreeListEntry* m_pMouseDownEntry;
SvTreeListEntry* m_pLastActiveEntry;
Color m_aOriginalBackgroundColor;
Font m_aOriginalFont;
Color m_aOriginalBackgroundColor;
vcl::Font m_aOriginalFont;
public:
OCreationList( OTasksWindow& _rParent );

View File

@ -74,7 +74,7 @@ void OApplicationSwapWindow::ImplInitSettings( bool bFont, bool bForeground, boo
const StyleSettings& rStyleSettings = GetSettings().GetStyleSettings();
if( bFont )
{
Font aFont;
vcl::Font aFont;
aFont = rStyleSettings.GetFieldFont();
aFont.SetColor( rStyleSettings.GetWindowTextColor() );
SetPointFont( aFont );

View File

@ -136,7 +136,7 @@ void OTitleWindow::ImplInitSettings( bool bFont, bool bForeground, bool bBackgro
const StyleSettings& rStyleSettings = GetSettings().GetStyleSettings();
if( bFont )
{
Font aFont;
vcl::Font aFont;
aFont = rStyleSettings.GetFieldFont();
aFont.SetColor( rStyleSettings.GetWindowTextColor() );
SetPointFont( aFont );
@ -154,7 +154,7 @@ void OTitleWindow::ImplInitSettings( bool bFont, bool bForeground, bool bBackgro
Window* pWindows [] = { &m_aSpace1, &m_aSpace2, &m_aTitle};
for (size_t i=0; i < sizeof(pWindows)/sizeof(pWindows[0]); ++i)
{
Font aFont = pWindows[i]->GetFont();
vcl::Font aFont = pWindows[i]->GetFont();
aFont.SetWeight(WEIGHT_BOLD);
pWindows[i]->SetFont(aFont);
pWindows[i]->SetTextColor( aStyle.GetLightColor() );

View File

@ -153,7 +153,7 @@ void OAppBorderWindow::ImplInitSettings()
const StyleSettings& rStyleSettings = GetSettings().GetStyleSettings();
if( true )
{
Font aFont;
vcl::Font aFont;
aFont = rStyleSettings.GetFieldFont();
aFont.SetColor( rStyleSettings.GetWindowTextColor() );
SetPointFont( aFont );
@ -546,7 +546,7 @@ void OApplicationView::ImplInitSettings()
const StyleSettings& rStyleSettings = GetSettings().GetStyleSettings();
if( true )
{
Font aFont;
vcl::Font aFont;
aFont = rStyleSettings.GetFieldFont();
aFont.SetColor( rStyleSettings.GetWindowTextColor() );
SetPointFont( aFont );

View File

@ -63,7 +63,7 @@ void OSplitterView::ImplInitSettings( bool bFont, bool bForeground, bool bBackgr
if ( bFont )
{
Font aFont = rStyleSettings.GetAppFont();
vcl::Font aFont = rStyleSettings.GetAppFont();
if ( IsControlFont() )
aFont.Merge( GetControlFont() );
SetPointFont( aFont );

View File

@ -32,7 +32,7 @@ namespace dbaui
if (!_pViewData)
_pViewData = pView->GetViewDataItem( pEntry, this );
pView->Push(PUSH_ALL);
Font aFont( pView->GetFont());
vcl::Font aFont( pView->GetFont());
aFont.SetWeight(WEIGHT_BOLD);
pView->Control::SetFont( aFont );
_pViewData->maSize = Size(pView->GetTextWidth(GetText()), pView->GetTextHeight());
@ -51,7 +51,7 @@ namespace dbaui
if (m_bEmphasized)
{
rDev.Push(PUSH_ALL);
Font aFont( rDev.GetFont());
vcl::Font aFont( rDev.GetFont());
aFont.SetWeight(WEIGHT_BOLD);
rDev.SetFont( aFont );
Point aPos(rPos);

View File

@ -45,8 +45,8 @@ void OMarkableTreeListBox::Paint(const Rectangle& _rRect)
{
if (!IsEnabled())
{
Font aOldFont = GetFont();
Font aNewFont(aOldFont);
vcl::Font aOldFont = GetFont();
vcl::Font aNewFont(aOldFont);
StyleSettings aSystemStyle = Application::GetSettings().GetStyleSettings();
aNewFont.SetColor(aSystemStyle.GetDisableColor());

View File

@ -233,12 +233,12 @@ void OSqlEdit::ImplSetFont()
get_value_or( OUString() ) );
if ( sFontName.isEmpty() )
{
Font aTmpFont( OutputDevice::GetDefaultFont( DEFAULTFONT_FIXED, Application::GetSettings().GetUILanguageTag().getLanguageType(), 0 , this ) );
vcl::Font aTmpFont( OutputDevice::GetDefaultFont( DEFAULTFONT_FIXED, Application::GetSettings().GetUILanguageTag().getLanguageType(), 0 , this ) );
sFontName = aTmpFont.GetName();
}
Size aFontSize(
0, officecfg::Office::Common::Font::SourceViewFont::FontHeight::get() );
Font aFont( sFontName, aFontSize );
vcl::Font aFont( sFontName, aFontSize );
aStyleSettings.SetFieldFont(aFont);
aSettings.SetStyleSettings(aStyleSettings);
SetSettings(aSettings);

View File

@ -67,7 +67,7 @@ namespace svt
class Window;
class ToolBox;
class Font;
namespace vcl { class Font; }
class SvNumberFormatter;
class SfxFilter;

View File

@ -320,7 +320,7 @@ void ODatabaseImportExport::initialize()
}
if ( m_aFont.Name.isEmpty() )
{
Font aApplicationFont = OutputDevice::GetDefaultFont(
vcl::Font aApplicationFont = OutputDevice::GetDefaultFont(
DEFAULTFONT_SANS_UNICODE,
Application::GetSettings().GetUILanguageTag().getLanguageType(),
DEFAULTFONT_FLAGS_ONLYONE

View File

@ -1452,7 +1452,7 @@ void OJoinTableView::StateChanged( StateChangedType nType )
{
const StyleSettings& rStyleSettings = GetSettings().GetStyleSettings();
Font aFont = rStyleSettings.GetGroupFont();
vcl::Font aFont = rStyleSettings.GetGroupFont();
if ( IsControlFont() )
aFont.Merge( GetControlFont() );
SetZoomedPointFont( aFont );

View File

@ -135,7 +135,7 @@ OSelectionBrowseBox::OSelectionBrowseBox( Window* pParent )
// switch off triState of ::com::sun::star::form::CheckBox
m_pVisibleCell->GetBox().EnableTriState( false );
Font aTitleFont = OutputDevice::GetDefaultFont( DEFAULTFONT_SANS_UNICODE,Window::GetSettings().GetLanguageTag().getLanguageType(),DEFAULTFONT_FLAGS_ONLYONE);
vcl::Font aTitleFont = OutputDevice::GetDefaultFont( DEFAULTFONT_SANS_UNICODE,Window::GetSettings().GetLanguageTag().getLanguageType(),DEFAULTFONT_FLAGS_ONLYONE);
aTitleFont.SetSize(Size(0, 6));
SetTitleFont(aTitleFont);
@ -330,7 +330,7 @@ void OSelectionBrowseBox::Init()
SetHeaderBar(pNewHeaderBar);
SetMode(m_nMode);
Font aFont( GetDataWindow().GetFont() );
vcl::Font aFont( GetDataWindow().GetFont() );
aFont.SetWeight( WEIGHT_NORMAL );
GetDataWindow().SetFont( aFont );

View File

@ -478,7 +478,7 @@ void OTableWindow::Resize()
void OTableWindow::SetBoldTitle( bool bBold )
{
Font aFont = m_aTitle.GetFont();
vcl::Font aFont = m_aTitle.GetFont();
aFont.SetWeight( bBold?WEIGHT_BOLD:WEIGHT_NORMAL );
m_aTitle.SetFont( aFont );
m_aTitle.Invalidate();
@ -554,7 +554,7 @@ void OTableWindow::StateChanged( StateChangedType nType )
{
const StyleSettings& rStyleSettings = GetSettings().GetStyleSettings();
Font aFont = rStyleSettings.GetGroupFont();
vcl::Font aFont = rStyleSettings.GetGroupFont();
if ( IsControlFont() )
aFont.Merge( GetControlFont() );
SetZoomedPointFont( aFont );

View File

@ -48,7 +48,7 @@ OTableWindowTitle::OTableWindowTitle( OTableWindow* pParent ) :
SetBackground(Wallpaper(Color(aSystemStyle.GetFaceColor())));
SetTextColor(aSystemStyle.GetButtonTextColor());
Font aFont( GetFont() );
vcl::Font aFont( GetFont() );
aFont.SetTransparent( true );
SetFont( aFont );
}
@ -173,7 +173,7 @@ void OTableWindowTitle::StateChanged( StateChangedType nType )
{
const StyleSettings& rStyleSettings = GetSettings().GetStyleSettings();
Font aFont = rStyleSettings.GetGroupFont();
vcl::Font aFont = rStyleSettings.GetGroupFont();
if ( IsControlFont() )
aFont.Merge( GetControlFont() );
SetZoomedPointFont( aFont );

View File

@ -57,7 +57,7 @@ void OTableRowView::Init()
{
EditBrowseBox::Init();
Font aFont( GetDataWindow().GetFont() );
vcl::Font aFont( GetDataWindow().GetFont() );
aFont.SetWeight( WEIGHT_NORMAL );
GetDataWindow().SetFont( aFont );

View File

@ -122,7 +122,7 @@ void OTableBorderWindow::ImplInitSettings( bool bFont, bool bForeground, bool bB
if ( bFont )
{
Font aFont = rStyleSettings.GetAppFont();
vcl::Font aFont = rStyleSettings.GetAppFont();
if ( IsControlFont() )
aFont.Merge( GetControlFont() );
SetPointFont( aFont );

View File

@ -537,8 +537,8 @@ void ExtensionBox_Impl::DrawRow( const Rectangle& rRect, const TEntry_Impl pEntr
DrawImage( aPos, Size( ICON_WIDTH, ICON_HEIGHT ), aImage );
// Setup fonts
Font aStdFont( GetFont() );
Font aBoldFont( aStdFont );
vcl::Font aStdFont( GetFont() );
vcl::Font aBoldFont( aStdFont );
aBoldFont.SetWeight( WEIGHT_BOLD );
SetFont( aBoldFont );
long aTextHeight = GetTextHeight();

View File

@ -625,7 +625,7 @@ void SplashScreen::Paint( const Rectangle&)
_vdev.SetFillColor( _cProgressBarColor );
_vdev.SetLineColor();
_vdev.DrawRect(Rectangle(_tlx+_barspace, _tly+_barspace, _tlx+_barspace+length, _tly+_barheight-_barspace));
Font aFont;
vcl::Font aFont;
aFont.SetSize(Size(0, 12));
aFont.SetAlign(ALIGN_BASELINE);
_vdev.SetFont(aFont);

View File

@ -87,7 +87,7 @@ namespace
basegfx::B2DPolyPolygon maClipPolyPoygon;
/// font, etc.
Font maFont;
vcl::Font maFont;
RasterOp maRasterOp;
ComplexTextLayoutMode mnLayoutMode;
LanguageType maLanguageType;
@ -175,8 +175,8 @@ namespace
bool getClipPolyPolygonActive() const { return mbClipPolyPolygonActive; }
void setClipPolyPolygonActive(bool bNew) { if(bNew != mbClipPolyPolygonActive) mbClipPolyPolygonActive = bNew; }
const Font& getFont() const { return maFont; }
void setFont(const Font& rFont) { if(rFont != maFont) maFont = rFont; }
const vcl::Font& getFont() const { return maFont; }
void setFont(const vcl::Font& rFont) { if(rFont != maFont) maFont = rFont; }
const RasterOp& getRasterOp() const { return maRasterOp; }
void setRasterOp(const RasterOp& rRasterOp) { if(rRasterOp != maRasterOp) maRasterOp = rRasterOp; }
@ -302,7 +302,7 @@ namespace
{
if(pLast->getFont().GetAlign() != pTip->getFont().GetAlign())
{
Font aFont(pLast->getFont());
vcl::Font aFont(pLast->getFont());
aFont.SetAlign(pTip->getFont().GetAlign());
pLast->setFont(aFont);
}
@ -1200,7 +1200,7 @@ namespace
}
/** helper to decide UnderlineAbove for text primitives */
bool isUnderlineAbove(const Font& rFont)
bool isUnderlineAbove(const vcl::Font& rFont)
{
if(!rFont.IsVertical())
{
@ -1222,7 +1222,7 @@ namespace
basegfx::B2DVector& rAlignmentOffset,
PropertyHolder& rProperty)
{
const Font& rFont = rProperty.getFont();
const vcl::Font& rFont = rProperty.getFont();
basegfx::B2DVector aFontScaling;
rFontAttribute = drawinglayer::attribute::FontAttribute(
@ -1273,7 +1273,7 @@ namespace
PropertyHolder& rProperty)
{
drawinglayer::primitive2d::BasePrimitive2D* pResult = 0;
const Font& rFont = rProperty.getFont();
const vcl::Font& rFont = rProperty.getFont();
basegfx::B2DVector aAlignmentOffset(0.0, 0.0);
if(nTextLength)
@ -2121,7 +2121,7 @@ namespace
// for sub-Mteafile contents, do start with new, default render state
// #i124686# ...but copy font, this is already set accordingly
Font aTargetFont = rPropertyHolders.Current().getFont();
vcl::Font aTargetFont = rPropertyHolders.Current().getFont();
rPropertyHolders.PushDefault();
rPropertyHolders.Current().setFont(aTargetFont);
@ -2660,7 +2660,7 @@ namespace
// playing the Metafile)
if(rPropertyHolders.Current().getFont().GetAlign() != aNewTextAlign)
{
Font aNewFont(rPropertyHolders.Current().getFont());
vcl::Font aNewFont(rPropertyHolders.Current().getFont());
aNewFont.SetAlign(aNewTextAlign);
rPropertyHolders.Current().setFont(aNewFont);
}
@ -2735,7 +2735,7 @@ namespace
{
// this should not happen but i got Metafiles where this was the
// case. A height needs to be guessed (similar to OutputDevice::ImplNewFont())
Font aCorrectedFont(pA->GetFont());
vcl::Font aCorrectedFont(pA->GetFont());
// guess 16 pixel (as in VCL)
aFontSize = Size(0, 16);

View File

@ -155,7 +155,7 @@ namespace drawinglayer
releaseGlobalVirtualDevice();
}
void TextLayouterDevice::setFont(const Font& rFont)
void TextLayouterDevice::setFont(const vcl::Font& rFont)
{
mrDevice.SetFont( rFont );
}
@ -365,7 +365,7 @@ namespace drawinglayer
{
namespace primitive2d
{
Font getVclFontFromFontAttribute(
vcl::Font getVclFontFromFontAttribute(
const attribute::FontAttribute& rFontAttribute,
double fFontScaleX,
double fFontScaleY,
@ -381,7 +381,7 @@ namespace drawinglayer
// for WIN32 systems, start with creating an unscaled font. If FontScaling
// is wanted, that width needs to be adapted using FontMetric again to get a
// width of the unscaled font
Font aRetval(
vcl::Font aRetval(
rFontAttribute.getFamilyName(),
rFontAttribute.getStyleName(),
Size(0, nHeight));
@ -391,7 +391,7 @@ namespace drawinglayer
// FontWidth when no scaling is used to explicitly have that zero when e.g. the
// Font would be recorded in a MetaFile (The MetaFile FontAction WILL record a
// set FontWidth; import that in a WIN32 system, and trouble is there)
Font aRetval(
vcl::Font aRetval(
rFontAttribute.getFamilyName(),
rFontAttribute.getStyleName(),
Size(bFontIsScaled ? nWidth : 0, nHeight));
@ -432,7 +432,7 @@ namespace drawinglayer
attribute::FontAttribute getFontAttributeFromVclFont(
basegfx::B2DVector& o_rSize,
const Font& rFont,
const vcl::Font& rFont,
bool bRTL,
bool bBiDiStrong)
{

View File

@ -139,7 +139,7 @@ namespace drawinglayer
if(basegfx::fTools::more(aFontScaling.getX(), 0.0) && basegfx::fTools::more(aFontScaling.getY(), 0.0))
{
// Get the VCL font (use FontHeight as FontWidth)
Font aFont(primitive2d::getVclFontFromFontAttribute(
vcl::Font aFont(primitive2d::getVclFontFromFontAttribute(
rTextCandidate.getFontAttribute(),
aFontScaling.getX(),
aFontScaling.getY(),

View File

@ -1996,7 +1996,7 @@ void EditDoc::RemoveItemsFromPool(const ContentNode& rNode)
void CreateFont( SvxFont& rFont, const SfxItemSet& rSet, bool bSearchInParent, short nScriptType )
{
Font aPrevFont( rFont );
vcl::Font aPrevFont( rFont );
rFont.SetAlign( ALIGN_BASELINE );
rFont.SetTransparent( true );
@ -2255,7 +2255,7 @@ EditPaM EditDoc::RemoveText()
ContentNode* pPrevFirstNode = GetObject(0);
SfxStyleSheet* pPrevStyle = pPrevFirstNode->GetStyleSheet();
SfxItemSet aPrevSet( pPrevFirstNode->GetContentAttribs().GetItems() );
Font aPrevFont( pPrevFirstNode->GetCharAttribs().GetDefFont() );
vcl::Font aPrevFont( pPrevFirstNode->GetCharAttribs().GetDefFont() );
ImplDestroyContents();

View File

@ -1747,7 +1747,7 @@ void EditEngine::RemoveAttribs( const ESelection& rSelection, bool bRemoveParaAt
pImpEditEngine->FormatAndUpdate();
}
Font EditEngine::GetStandardFont( sal_Int32 nPara )
vcl::Font EditEngine::GetStandardFont( sal_Int32 nPara )
{
return GetStandardSvxFont( nPara );
}
@ -2578,7 +2578,7 @@ SfxItemPool& EditEngine::GetGlobalItemPool()
return *pGlobalPool;
}
void EditEngine::SetFontInfoInItemSet( SfxItemSet& rSet, const Font& rFont )
void EditEngine::SetFontInfoInItemSet( SfxItemSet& rSet, const vcl::Font& rFont )
{
SvxFont aSvxFont( rFont );
SetFontInfoInItemSet( rSet, aSvxFont );
@ -2609,7 +2609,7 @@ void EditEngine::SetFontInfoInItemSet( SfxItemSet& rSet, const SvxFont& rFont )
rSet.Put( SvxCharReliefItem( rFont.GetRelief(), EE_CHAR_RELIEF ) );
}
Font EditEngine::CreateFontFromItemSet( const SfxItemSet& rItemSet, sal_uInt16 nScriptType )
vcl::Font EditEngine::CreateFontFromItemSet( const SfxItemSet& rItemSet, sal_uInt16 nScriptType )
{
SvxFont aFont;
CreateFont( aFont, rItemSet, true, nScriptType );

View File

@ -704,7 +704,7 @@ EESpellState EditView::StartThesaurus()
}
void EditView::StartTextConversion(
LanguageType nSrcLang, LanguageType nDestLang, const Font *pDestFont,
LanguageType nSrcLang, LanguageType nDestLang, const vcl::Font *pDestFont,
sal_Int32 nOptions, bool bIsInteractive, bool bMultipleDoc )
{
pImpEditView->pEditEngine->pImpEditEngine->Convert( this, nSrcLang, nDestLang, pDestFont, nOptions, bIsInteractive, bMultipleDoc );

View File

@ -652,7 +652,7 @@ void EditHTMLParser::ImpSetStyleSheet( sal_uInt16 nHLevel )
// Choose a proportional Font for Pre
if ( nHLevel == STYLE_PRE )
{
Font aFont = OutputDevice::GetDefaultFont( DEFAULTFONT_FIXED, LANGUAGE_SYSTEM, 0 );
vcl::Font aFont = OutputDevice::GetDefaultFont( DEFAULTFONT_FIXED, LANGUAGE_SYSTEM, 0 );
SvxFontItem aFontItem( aFont.GetFamily(), aFont.GetName(), OUString(), aFont.GetPitch(), aFont.GetCharSet(), EE_CHAR_FONTINFO );
aItems.Put( aFontItem );

View File

@ -151,7 +151,7 @@ void EditRTFParser::AddRTFDefaultValues( const EditPaM& rStart, const EditPaM& r
MapMode _aEditMapMode(mpEditEngine->GetRefDevice()->GetMapMode().GetMapUnit());
aSz = mpEditEngine->GetRefDevice()->LogicToLogic(aSz, &aPntMode, &_aEditMapMode);
SvxFontHeightItem aFontHeightItem( aSz.Width(), 100, EE_CHAR_FONTHEIGHT );
Font aDefFont( GetDefFont() );
vcl::Font aDefFont( GetDefFont() );
SvxFontItem aFontItem( aDefFont.GetFamily(), aDefFont.GetName(),
aDefFont.GetStyleName(), aDefFont.GetPitch(), aDefFont.GetCharSet(), EE_CHAR_FONTINFO );

View File

@ -107,7 +107,7 @@ public:
GetDestCharSet() const { return eDestCharSet; }
sal_uInt16 GetDefTab() const { return nDefTab; }
Font GetDefFont() { return GetFont( nDefFont ); }
vcl::Font GetDefFont() { return GetFont( nDefFont ); }
EditPaM GetCurPaM() const { return aCurSel.Max(); }
};

View File

@ -915,14 +915,14 @@ public:
ImpSpell( EditView* pEditView );
// text conversion functions
void Convert( EditView* pEditView, LanguageType nSrcLang, LanguageType nDestLang, const Font *pDestFont, sal_Int32 nOptions, bool bIsInteractive, bool bMultipleDoc );
void Convert( EditView* pEditView, LanguageType nSrcLang, LanguageType nDestLang, const vcl::Font *pDestFont, sal_Int32 nOptions, bool bIsInteractive, bool bMultipleDoc );
void ImpConvert( OUString &rConvTxt, LanguageType &rConvTxtLang, EditView* pEditView, LanguageType nSrcLang, const ESelection &rConvRange,
bool bAllowImplicitChangesForNotConvertibleText, LanguageType nTargetLang, const Font *pTargetFont );
bool bAllowImplicitChangesForNotConvertibleText, LanguageType nTargetLang, const vcl::Font *pTargetFont );
ConvInfo * GetConvInfo() const { return pConvInfo; }
bool HasConvertibleTextPortion( LanguageType nLang );
void SetLanguageAndFont( const ESelection &rESel,
LanguageType nLang, sal_uInt16 nLangWhichId,
const Font *pFont, sal_uInt16 nFontWhichId );
const vcl::Font *pFont, sal_uInt16 nFontWhichId );
// returns true if input sequence checking should be applied
bool IsInputSequenceCheckingRequired( sal_Unicode nChar, const EditSelection& rCurSel ) const;

View File

@ -368,7 +368,7 @@ void ImpEditEngine::FormatDoc()
long nY = 0;
bool bGrow = false;
Font aOldFont( GetRefDevice()->GetFont() );
vcl::Font aOldFont( GetRefDevice()->GetFont() );
// Here already, so that not always in CreateLines...
bool bMapChanged = ImpCheckRefMapMode();
@ -2857,7 +2857,7 @@ void ImpEditEngine::Paint( OutputDevice* pOutDev, Rectangle aClipRect, Point aSt
Point aRedLineTmpPos;
DBG_ASSERT( GetParaPortions().Count(), "No ParaPortion?!" );
SvxFont aTmpFont( GetParaPortions()[0]->GetNode()->GetCharAttribs().GetDefFont() );
Font aOldFont( pOutDev->GetFont() );
vcl::Font aOldFont( pOutDev->GetFont() );
vcl::PDFExtOutDevData* pPDFExtOutDevData = PTR_CAST( vcl::PDFExtOutDevData, pOutDev->GetExtOutDevData() );
// In the case of rotated text is aStartPos considered TopLeft because
@ -3186,7 +3186,7 @@ void ImpEditEngine::Paint( OutputDevice* pOutDev, Rectangle aClipRect, Point aSt
pTmpDXArray.reset(new long[ aText.getLength() ]);
pDXArray = pTmpDXArray.get();
Font _aOldFont( GetRefDevice()->GetFont() );
vcl::Font _aOldFont( GetRefDevice()->GetFont() );
aTmpFont.SetPhysFont( GetRefDevice() );
aTmpFont.QuickGetTextSize( GetRefDevice(), aText, nTextStart, nTextLen, pTmpDXArray.get() );
if ( aStatus.DoRestoreFont() )
@ -3216,7 +3216,7 @@ void ImpEditEngine::Paint( OutputDevice* pOutDev, Rectangle aClipRect, Point aSt
// crash when accessing 0 pointer in pDXArray
pTmpDXArray.reset(new long[ aText.getLength() ]);
pDXArray = pTmpDXArray.get();
Font _aOldFont( GetRefDevice()->GetFont() );
vcl::Font _aOldFont( GetRefDevice()->GetFont() );
aTmpFont.SetPhysFont( GetRefDevice() );
aTmpFont.QuickGetTextSize( GetRefDevice(), aText, 0, aText.getLength(), pTmpDXArray.get() );
if ( aStatus.DoRestoreFont() )
@ -3925,7 +3925,7 @@ void ImpEditEngine::ShowParagraph( sal_Int32 nParagraph, bool bShow )
{
if ( pPPortion->IsInvalid() )
{
Font aOldFont( GetRefDevice()->GetFont() );
vcl::Font aOldFont( GetRefDevice()->GetFont() );
CreateLines( nParagraph, 0 ); // 0: No TextRanger
if ( aStatus.DoRestoreFont() )
GetRefDevice()->SetFont( aOldFont );

View File

@ -1551,7 +1551,7 @@ bool ImpEditEngine::HasConvertibleTextPortion( LanguageType nSrcLang )
void ImpEditEngine::Convert( EditView* pEditView,
LanguageType nSrcLang, LanguageType nDestLang, const Font *pDestFont,
LanguageType nSrcLang, LanguageType nDestLang, const vcl::Font *pDestFont,
sal_Int32 nOptions, bool bIsInteractive, bool bMultipleDoc )
{
// modified version of ImpEditEngine::Spell
@ -1641,7 +1641,7 @@ void ImpEditEngine::Convert( EditView* pEditView,
void ImpEditEngine::SetLanguageAndFont(
const ESelection &rESel,
LanguageType nLang, sal_uInt16 nLangWhichId,
const Font *pFont, sal_uInt16 nFontWhichId )
const vcl::Font *pFont, sal_uInt16 nFontWhichId )
{
ESelection aOldSel = pActiveView->GetSelection();
pActiveView->SetSelection( rESel );
@ -1674,7 +1674,7 @@ void ImpEditEngine::SetLanguageAndFont(
void ImpEditEngine::ImpConvert( OUString &rConvTxt, LanguageType &rConvTxtLang,
EditView* pEditView, LanguageType nSrcLang, const ESelection &rConvRange,
bool bAllowImplicitChangesForNotConvertibleText,
LanguageType nTargetLang, const Font *pTargetFont )
LanguageType nTargetLang, const vcl::Font *pTargetFont )
{
// modified version of ImpEditEngine::ImpSpell

View File

@ -46,7 +46,7 @@ TextConvWrapper::TextConvWrapper( Window* pWindow,
const Reference< XComponentContext >& rxContext,
const Locale& rSourceLocale,
const Locale& rTargetLocale,
const Font* pTargetFont,
const vcl::Font* pTargetFont,
sal_Int32 nOptions,
bool bIsInteractive,
bool bIsStart,
@ -245,7 +245,7 @@ bool TextConvWrapper::ConvContinue_impl()
void TextConvWrapper::SetLanguageAndFont( const ESelection &rESel,
LanguageType nLang, sal_uInt16 nLangWhichId,
const Font *pFont, sal_uInt16 nFontWhichId )
const vcl::Font *pFont, sal_uInt16 nFontWhichId )
{
ESelection aOldSel = m_pEditView->GetSelection();
m_pEditView->SetSelection( rESel );

View File

@ -90,7 +90,7 @@ protected:
void SetLanguageAndFont( const ESelection &rESel,
LanguageType nLang, sal_uInt16 nLangWhichId,
const Font *pFont, sal_uInt16 nFontWhichId );
const vcl::Font *pFont, sal_uInt16 nFontWhichId );
public:
@ -98,7 +98,7 @@ public:
const ::com::sun::star::uno::Reference< ::com::sun::star::uno::XComponentContext >& rxContext,
const ::com::sun::star::lang::Locale& rSourceLocale,
const ::com::sun::star::lang::Locale& rTargetLocale,
const Font* pTargetFont,
const vcl::Font* pTargetFont,
sal_Int32 nOptions,
bool bIsInteractive,
bool bIsStart, EditView* pView );

View File

@ -34,7 +34,7 @@ TYPEINIT1(SvxBulletItem,SfxPoolItem);
void SvxBulletItem::StoreFont( SvStream& rStream, const Font& rFont )
void SvxBulletItem::StoreFont( SvStream& rStream, const vcl::Font& rFont )
{
sal_uInt16 nTemp;
@ -61,9 +61,9 @@ void SvxBulletItem::StoreFont( SvStream& rStream, const Font& rFont )
Font SvxBulletItem::CreateFont( SvStream& rStream, sal_uInt16 nVer )
vcl::Font SvxBulletItem::CreateFont( SvStream& rStream, sal_uInt16 nVer )
{
Font aFont;
vcl::Font aFont;
Color aColor;
ReadColor( rStream, aColor ); aFont.SetColor( aColor );
sal_uInt16 nTemp;
@ -237,8 +237,8 @@ sal_uInt16 SvxBulletItem::GetVersion( sal_uInt16 /*nVersion*/ ) const
void SvxBulletItem::CopyValidProperties( const SvxBulletItem& rCopyFrom )
{
Font _aFont = GetFont();
Font aNewFont = rCopyFrom.GetFont();
vcl::Font _aFont = GetFont();
vcl::Font aNewFont = rCopyFrom.GetFont();
if ( rCopyFrom.IsValid( VALID_FONTNAME ) )
{
_aFont.SetName( aNewFont.GetName() );

View File

@ -219,7 +219,7 @@ SvxNumberFormat::SvxNumberFormat( SvStream &rStream )
rStream.ReadUInt16( hasBulletFont );
if ( hasBulletFont )
{
pBulletFont = new Font( );
pBulletFont = new vcl::Font( );
ReadFont( rStream, *pBulletFont );
}
else pBulletFont = NULL;
@ -345,7 +345,7 @@ SvxNumberFormat& SvxNumberFormat::operator=( const SvxNumberFormat& rFormat )
}
DELETEZ(pBulletFont);
if(rFormat.pBulletFont)
pBulletFont = new Font(*rFormat.pBulletFont);
pBulletFont = new vcl::Font(*rFormat.pBulletFont);
return *this;
}
@ -443,10 +443,10 @@ sal_Int16 SvxNumberFormat::GetVertOrient() const
return eVertOrient;
}
void SvxNumberFormat::SetBulletFont(const Font* pFont)
void SvxNumberFormat::SetBulletFont(const vcl::Font* pFont)
{
delete pBulletFont;
pBulletFont = pFont ? new Font(*pFont): 0;
pBulletFont = pFont ? new vcl::Font(*pFont): 0;
}
void SvxNumberFormat::SetPositionAndSpaceMode( SvxNumPositionAndSpaceMode ePositionAndSpaceMode )

View File

@ -39,7 +39,7 @@ SvxFont::SvxFont()
SetLanguage(LANGUAGE_SYSTEM);
}
SvxFont::SvxFont( const Font &rFont )
SvxFont::SvxFont( const vcl::Font &rFont )
: Font( rFont )
{
nKern = nEsc = 0;
@ -319,7 +319,7 @@ void SvxFont::DoOnCapitals(SvxDoCapitals &rDo) const
void SvxFont::SetPhysFont( OutputDevice *pOut ) const
{
const Font& rCurrentFont = pOut->GetFont();
const vcl::Font& rCurrentFont = pOut->GetFont();
if ( nPropr == 100 )
{
if ( !rCurrentFont.IsSameInstance( *this ) )
@ -337,9 +337,9 @@ void SvxFont::SetPhysFont( OutputDevice *pOut ) const
}
Font SvxFont::ChgPhysFont( OutputDevice *pOut ) const
vcl::Font SvxFont::ChgPhysFont( OutputDevice *pOut ) const
{
Font aOldFont( pOut->GetFont() );
vcl::Font aOldFont( pOut->GetFont() );
SetPhysFont( pOut );
return aOldFont;
}
@ -566,7 +566,7 @@ void SvxFont::DrawPrev( OutputDevice *pOut, Printer* pPrinter,
}
SvxFont& SvxFont::operator=( const Font& rFont )
SvxFont& SvxFont::operator=( const vcl::Font& rFont )
{
Font::operator=( rFont );
return *this;

View File

@ -3470,7 +3470,7 @@ void GetDefaultFonts( SvxFontItem& rLatin, SvxFontItem& rAsian, SvxFontItem& rCo
for ( sal_uInt16 n = 0; n < nItemCnt; ++n )
{
Font aFont( OutputDevice::GetDefaultFont( aOutTypeArr[ n ].nFontType,
vcl::Font aFont( OutputDevice::GetDefaultFont( aOutTypeArr[ n ].nFontType,
aOutTypeArr[ n ].nLanguage,
DEFAULTFONT_FLAGS_ONLYONE, 0 ) );
SvxFontItem* pItem = aItemArr[ n ];

View File

@ -82,7 +82,7 @@ namespace editeng
// save the applications from always converting to this
// type in their implementations
LanguageType m_nTargetLang; // target language of new replacement text
const Font* m_pTargetFont; // target font of new replacement text
const vcl::Font* m_pTargetFont; // target font of new replacement text
sal_Int32 m_nConvOptions; // text conversion options (as used by 'getConversions')
bool m_bIsInteractive; // specifies if the conversion requires user interaction
// (and likeley a specialised dialog) or if it is to run
@ -123,7 +123,7 @@ namespace editeng
const Reference< XComponentContext >& rxContext,
const Locale& _rSourceLocale,
const Locale& _rTargetLocale,
const Font* _pTargetFont,
const vcl::Font* _pTargetFont,
sal_Int32 _nConvOptions,
bool _bIsInteractive,
HangulHanjaConversion* _pAntiImpl );
@ -137,7 +137,7 @@ namespace editeng
inline LanguageType GetSourceLang() const { return m_nSourceLang; }
inline LanguageType GetTargetLang() const { return m_nTargetLang; }
inline const Font * GetTargetFont() const { return m_pTargetFont; }
inline const vcl::Font * GetTargetFont() const { return m_pTargetFont; }
inline sal_Int32 GetConvOptions() const { return m_nConvOptions; }
inline bool IsInteractive() const { return m_bIsInteractive; }
@ -233,7 +233,7 @@ namespace editeng
const Reference< XComponentContext >& rxContext,
const Locale& _rSourceLocale,
const Locale& _rTargetLocale,
const Font* _pTargetFont,
const vcl::Font* _pTargetFont,
sal_Int32 _nOptions,
bool _bIsInteractive,
HangulHanjaConversion* _pAntiImpl )
@ -968,7 +968,7 @@ namespace editeng
HangulHanjaConversion::HangulHanjaConversion( Window* _pUIParent,
const Reference< XComponentContext >& rxContext,
const Locale& _rSourceLocale, const Locale& _rTargetLocale,
const Font* _pTargetFont,
const vcl::Font* _pTargetFont,
sal_Int32 _nOptions, bool _bIsInteractive)
:m_pImpl( new HangulHanjaConversion_Impl( _pUIParent, rxContext, _rSourceLocale, _rTargetLocale, _pTargetFont, _nOptions, _bIsInteractive, this ) )
{
@ -998,7 +998,7 @@ namespace editeng
return m_pImpl->GetTargetLang();
}
const Font * HangulHanjaConversion::GetTargetFont( ) const
const vcl::Font * HangulHanjaConversion::GetTargetFont( ) const
{
return m_pImpl->GetTargetFont();
}

View File

@ -853,12 +853,12 @@ bool Outliner::Collapse( Paragraph* pPara )
}
Font Outliner::ImpCalcBulletFont( sal_Int32 nPara ) const
vcl::Font Outliner::ImpCalcBulletFont( sal_Int32 nPara ) const
{
const SvxNumberFormat* pFmt = GetNumberFormat( nPara );
DBG_ASSERT( pFmt && ( pFmt->GetNumberingType() != SVX_NUM_BITMAP ) && ( pFmt->GetNumberingType() != SVX_NUM_NUMBER_NONE ), "ImpCalcBulletFont: Missing or BitmapBullet!" );
Font aStdFont;
vcl::Font aStdFont;
if ( !pEditEngine->IsFlatMode() )
{
ESelection aSel( nPara, 0, nPara, 0 );
@ -869,8 +869,8 @@ Font Outliner::ImpCalcBulletFont( sal_Int32 nPara ) const
aStdFont = pEditEngine->GetStandardFont( nPara );
}
Font aBulletFont;
const Font *pSourceFont = 0;
vcl::Font aBulletFont;
const vcl::Font *pSourceFont = 0;
if ( pFmt->GetNumberingType() == SVX_NUM_CHAR_SPECIAL )
{
pSourceFont = pFmt->GetBulletFont();
@ -949,11 +949,11 @@ void Outliner::PaintBullet( sal_Int32 nPara, const Point& rStartPos,
{
if( pFmt->GetNumberingType() != SVX_NUM_BITMAP )
{
Font aBulletFont( ImpCalcBulletFont( nPara ) );
vcl::Font aBulletFont( ImpCalcBulletFont( nPara ) );
// Use baseline
bool bSymbol = pFmt->GetNumberingType() == SVX_NUM_CHAR_SPECIAL;
aBulletFont.SetAlign( bSymbol ? ALIGN_BOTTOM : ALIGN_BASELINE );
Font aOldFont = pOutDev->GetFont();
vcl::Font aOldFont = pOutDev->GetFont();
pOutDev->SetFont( aBulletFont );
ParagraphInfos aParaInfos = pEditEngine->GetParagraphInfos( nPara );
@ -990,7 +990,7 @@ void Outliner::PaintBullet( sal_Int32 nPara, const Point& rStartPos,
aTextPos = aRotatedPos;
// Translation...
aTextPos += rOrigin;
Font aRotatedFont( aBulletFont );
vcl::Font aRotatedFont( aBulletFont );
aRotatedFont.SetOrientation( nOrientation );
pOutDev->SetFont( aRotatedFont );
}
@ -1004,7 +1004,7 @@ void Outliner::PaintBullet( sal_Int32 nPara, const Point& rStartPos,
if(bStrippingPortions)
{
const Font aSvxFont(pOutDev->GetFont());
const vcl::Font aSvxFont(pOutDev->GetFont());
boost::scoped_array<long> pBuf(new long[ pPara->GetText().getLength() ]);
pOutDev->GetTextArray( pPara->GetText(), pBuf.get() );
@ -1479,8 +1479,8 @@ Size Outliner::ImplGetBulletSize( sal_Int32 nPara )
{
OUString aBulletText = ImplGetBulletText( nPara );
OutputDevice* pRefDev = pEditEngine->GetRefDevice();
Font aBulletFont( ImpCalcBulletFont( nPara ) );
Font aRefFont( pRefDev->GetFont());
vcl::Font aBulletFont( ImpCalcBulletFont( nPara ) );
vcl::Font aRefFont( pRefDev->GetFont());
pRefDev->SetFont( aBulletFont );
pPara->aBulSize.Width() = pRefDev->GetTextWidth( aBulletText );
pPara->aBulSize.Height() = pRefDev->GetTextHeight();
@ -1607,11 +1607,11 @@ Rectangle Outliner::ImpCalcBulletArea( sal_Int32 nPara, bool bAdjust, bool bRetu
// may prefer to print out on the baseline ...
if( ( pFmt->GetNumberingType() != SVX_NUM_NUMBER_NONE ) && ( pFmt->GetNumberingType() != SVX_NUM_BITMAP ) && ( pFmt->GetNumberingType() != SVX_NUM_CHAR_SPECIAL ) )
{
Font aBulletFont( ImpCalcBulletFont( nPara ) );
vcl::Font aBulletFont( ImpCalcBulletFont( nPara ) );
if ( aBulletFont.GetCharSet() != RTL_TEXTENCODING_SYMBOL )
{
OutputDevice* pRefDev = pEditEngine->GetRefDevice();
Font aOldFont = pRefDev->GetFont();
vcl::Font aOldFont = pRefDev->GetFont();
pRefDev->SetFont( aBulletFont );
FontMetric aMetric( pRefDev->GetFontMetric() );
// Leading on the first line ...

View File

@ -1270,7 +1270,7 @@ EESpellState OutlinerView::StartThesaurus()
}
void OutlinerView::StartTextConversion(
LanguageType nSrcLang, LanguageType nDestLang, const Font *pDestFont,
LanguageType nSrcLang, LanguageType nDestLang, const vcl::Font *pDestFont,
sal_Int32 nOptions, bool bIsInteractive, bool bMultipleDoc )
{
if (

View File

@ -646,7 +646,7 @@ SET_FONTALIGNMENT:
case RTF_F:
case RTF_AF:
{
const Font& rSVFont = GetFont( sal_uInt16(nTokenValue) );
const vcl::Font& rSVFont = GetFont( sal_uInt16(nTokenValue) );
SvxFontItem aTmpItem( rSVFont.GetFamily(),
rSVFont.GetName(), rSVFont.GetStyleName(),
rSVFont.GetPitch(), rSVFont.GetCharSet(),
@ -1804,7 +1804,7 @@ void SvxRTFParser::RTFPardPlain( int bPard, SfxItemSet** ppSet )
//we can fall back to the ansicpg set codeset
if (nDfltFont != -1)
{
const Font& rSVFont = GetFont(sal_uInt16(nDfltFont));
const vcl::Font& rSVFont = GetFont(sal_uInt16(nDfltFont));
SetEncoding(rSVFont.GetCharSet());
}
else
@ -1828,7 +1828,7 @@ void SvxRTFParser::SetDefault( int nToken, int nValue )
{
if( -1 == nValue )
nValue = 0;
const Font& rSVFont = GetFont( sal_uInt16(nValue) );
const vcl::Font& rSVFont = GetFont( sal_uInt16(nValue) );
SvxFontItem aTmpItem(
rSVFont.GetFamily(), rSVFont.GetName(),
rSVFont.GetStyleName(), rSVFont.GetPitch(),

View File

@ -90,7 +90,7 @@ SvxRTFParser::SvxRTFParser( SfxItemPool& rPool, SvStream& rIn,
aPardMap.insert( aPardMap.begin(), (sal_uInt16*)&aTmp,
(sal_uInt16*)&aTmp + (sizeof( RTFPardAttrMapIds ) / sizeof(sal_uInt16)) );
}
pDfltFont = new Font;
pDfltFont = new vcl::Font;
pDfltColor = new Color;
}
@ -465,7 +465,7 @@ void SvxRTFParser::ReadFontTable()
{
int nToken;
int _nOpenBrakets = 1; // the first was already detected earlier!!
Font* pFont = new Font();
vcl::Font* pFont = new vcl::Font();
short nFontNo(0), nInsFontNo (0);
OUString sAltNm, sFntNm;
bool bIsAltFntNm = false, bCheckNewFont;
@ -582,7 +582,7 @@ void SvxRTFParser::ReadFontTable()
pFont->SetName( sFntNm );
aFontTbl.insert( nInsFontNo, pFont );
pFont = new Font();
pFont = new vcl::Font();
pFont->SetCharSet( nSystemChar );
sAltNm = "";
sFntNm = "";
@ -814,10 +814,10 @@ OUString& SvxRTFParser::DelCharAtEnd( OUString& rStr, const sal_Unicode cDel )
}
const Font& SvxRTFParser::GetFont( sal_uInt16 nId )
const vcl::Font& SvxRTFParser::GetFont( sal_uInt16 nId )
{
SvxRTFFontTbl::const_iterator it = aFontTbl.find( nId );
const Font* pFont;
const vcl::Font* pFont;
if( it == aFontTbl.end() )
{
const SvxFontItem& rDfltFont = (const SvxFontItem&)

Some files were not shown because too many files have changed in this diff Show More