summaryrefslogtreecommitdiff
path: root/svtools
diff options
context:
space:
mode:
authorNorbert Thiebaud <nthiebaud@gmail.com>2016-01-16 12:20:45 -0600
committerNorbert Thiebaud <nthiebaud@gmail.com>2016-01-16 12:20:45 -0600
commit45654a1d4d96732912e6e4dc254c9612d3f241c0 (patch)
tree19f4ba915a56e53447980ce89fd46710167d7d23 /svtools
parent5d4f1f6f630d4382679087a4fb0da364c9c9692b (diff)
revert vcl patch series that brok Mac and Windows
revert: 9bc2f3de8672e812f3a67541c6d7069b434a7e42 vcl: add comment about ImplFontMetric::{Get|Set}LineHeight() 26371f105bc44e04469ec03fc5bb12505e651c6b vcl: FontAttributes::GetSlantType() -> FontAttributes::GetItalic() 2dd0b4317372b8022efe3911b38b4fa02956d8b9 vcl: font.hxx and metric.hxx cleanup, make ctors explicit and the dtor virtual 5ab13bf3ead3539e4ad847656da81e7eb6029652 vcl: tabify font.hxx f99550dae55e40e49bf9c9875053fe2abb4c71ca vcl: change Font::SetName() to Font::SetFamilyName() 2b297116cb6bb1061c43e5714e2609c8ee9f57d2 vcl: rename Font::GetName to Font::GetFamilyName Change-Id: I23f38921187d66b970ca815eb30dda4222a2da62
Diffstat (limited to 'svtools')
-rw-r--r--svtools/source/control/ctrlbox.cxx6
-rw-r--r--svtools/source/control/ctrltool.cxx14
-rw-r--r--svtools/source/control/stdmenu.cxx2
-rw-r--r--svtools/source/misc/sampletext.cxx58
4 files changed, 40 insertions, 40 deletions
diff --git a/svtools/source/control/ctrlbox.cxx b/svtools/source/control/ctrlbox.cxx
index 8bd7b594b08a..5c411202463c 100644
--- a/svtools/source/control/ctrlbox.cxx
+++ b/svtools/source/control/ctrlbox.cxx
@@ -1036,7 +1036,7 @@ void FontNameBox::Fill( const FontList* pList )
for ( sal_uInt16 i = 0; i < nFontCount; i++ )
{
const FontMetric& rFontMetric = pList->GetFontName( i );
- sal_uLong nIndex = InsertEntry( rFontMetric.GetFamilyName() );
+ sal_uLong nIndex = InsertEntry( rFontMetric.GetName() );
if ( nIndex != LISTBOX_ERROR )
{
if ( nIndex < mpFontList->size() ) {
@@ -1140,7 +1140,7 @@ void FontNameBox::UserDraw( const UserDrawEvent& rUDEvt )
Rectangle aTextRect;
// Preview the font name
- OUString sFontName = rFontMetric.GetFamilyName();
+ OUString sFontName = rFontMetric.GetName();
//If it shouldn't or can't draw its own name because it doesn't have the glyphs
if (!canRenderNameOfSelectedFont(*pRenderContext))
@@ -1171,7 +1171,7 @@ void FontNameBox::UserDraw( const UserDrawEvent& rUDEvt )
if (!bSymbolFont)
{
- const bool bNameBeginsWithLatinText = rFontMetric.GetFamilyName()[0] <= 'z';
+ const bool bNameBeginsWithLatinText = rFontMetric.GetName()[0] <= 'z';
if (bNameBeginsWithLatinText || !bUsingCorrectFont)
sSampleText = makeShortRepresentativeTextForSelectedFont(*pRenderContext);
diff --git a/svtools/source/control/ctrltool.cxx b/svtools/source/control/ctrltool.cxx
index ccbb3a13ef5f..fcaac738b646 100644
--- a/svtools/source/control/ctrltool.cxx
+++ b/svtools/source/control/ctrltool.cxx
@@ -259,7 +259,7 @@ void FontList::ImplInsertFonts( OutputDevice* pDevice, bool bAll,
if ( !bAll && (aFontMetric.GetType() == TYPE_RASTER) )
continue;
- OUString aSearchName(aFontMetric.GetFamilyName());
+ OUString aSearchName(aFontMetric.GetName());
ImplFontListNameInfo* pData;
sal_uLong nIndex;
aSearchName = ImplMakeSearchString(aSearchName);
@@ -483,13 +483,13 @@ OUString FontList::GetStyleName(const FontMetric& rInfo) const
OUString FontList::GetFontMapText( const FontMetric& rInfo ) const
{
- if ( rInfo.GetFamilyName().isEmpty() )
+ if ( rInfo.GetName().isEmpty() )
{
return OUString();
}
// Search Fontname
- ImplFontListNameInfo* pData = ImplFindByName( rInfo.GetFamilyName() );
+ ImplFontListNameInfo* pData = ImplFindByName( rInfo.GetName() );
if ( !pData )
{
if (maMapNotAvailable.isEmpty())
@@ -649,7 +649,7 @@ FontMetric FontList::Get(const OUString& rName, const OUString& rStyleName) cons
aInfo = *pFontMetric;
// set Fontname to keep FontAlias
- aInfo.SetFamilyName( rName );
+ aInfo.SetName( rName );
aInfo.SetStyleName( rStyleName );
return aInfo;
@@ -686,7 +686,7 @@ FontMetric FontList::Get(const OUString& rName,
aInfo = *pFontMetric;
// set Fontname to keep FontAlias
- aInfo.SetFamilyName( rName );
+ aInfo.SetName( rName );
return aInfo;
}
@@ -734,12 +734,12 @@ const sal_IntPtr* FontList::GetSizeAry( const FontMetric& rInfo ) const
}
// use standard sizes if no name
- if ( rInfo.GetFamilyName().isEmpty() )
+ if ( rInfo.GetName().isEmpty() )
return aStdSizeAry;
// first search fontname in order to use device from the matching font
OutputDevice* pDevice = mpDev;
- ImplFontListNameInfo* pData = ImplFindByName( rInfo.GetFamilyName() );
+ ImplFontListNameInfo* pData = ImplFindByName( rInfo.GetName() );
if ( pData )
pDevice = pData->mpFirst->GetDevice();
diff --git a/svtools/source/control/stdmenu.cxx b/svtools/source/control/stdmenu.cxx
index 6e0e55e8f4a9..55eb7ba54d92 100644
--- a/svtools/source/control/stdmenu.cxx
+++ b/svtools/source/control/stdmenu.cxx
@@ -57,7 +57,7 @@ void FontNameMenu::Fill( const FontList* pList )
sal_uInt16 nFontCount = ::std::min( pList->GetFontNameCount(), static_cast< sal_uInt16 >(100) );
for (sal_uInt16 i = 0; i < nFontCount; ++i)
{
- const OUString& rName = pList->GetFontName( i ).GetFamilyName();
+ const OUString& rName = pList->GetFontName( i ).GetName();
// sort with the I18nHelper
sal_uInt16 j = GetItemCount();
diff --git a/svtools/source/misc/sampletext.cxx b/svtools/source/misc/sampletext.cxx
index ebe0e7863ecd..4ba252b5702c 100644
--- a/svtools/source/misc/sampletext.cxx
+++ b/svtools/source/misc/sampletext.cxx
@@ -19,7 +19,7 @@
// that caused it to be added
static UScriptCode lcl_getHardCodedScriptNameForFont (const OutputDevice &rDevice)
{
- const OUString &rName = rDevice.GetFont().GetFamilyName();
+ const OUString &rName = rDevice.GetFont().GetName();
if (rName == "GB18030 Bitmap")
{
@@ -105,49 +105,49 @@ static UScriptCode lcl_getHardCodedScriptNameForFont (const OutputDevice &rDevic
bool isOpenSymbolFont(const vcl::Font &rFont)
{
- return rFont.GetFamilyName().equalsIgnoreAsciiCase("starsymbol") ||
- rFont.GetFamilyName().equalsIgnoreAsciiCase("opensymbol");
+ return rFont.GetName().equalsIgnoreAsciiCase("starsymbol") ||
+ rFont.GetName().equalsIgnoreAsciiCase("opensymbol");
}
bool isSymbolFont(const vcl::Font &rFont)
{
return (rFont.GetCharSet() == RTL_TEXTENCODING_SYMBOL) ||
- rFont.GetFamilyName().equalsIgnoreAsciiCase("Apple Color Emoji") ||
- rFont.GetFamilyName().equalsIgnoreAsciiCase("cmsy10") ||
- rFont.GetFamilyName().equalsIgnoreAsciiCase("cmex10") ||
- rFont.GetFamilyName().equalsIgnoreAsciiCase("esint10") ||
- rFont.GetFamilyName().equalsIgnoreAsciiCase("feta26") ||
- rFont.GetFamilyName().equalsIgnoreAsciiCase("jsMath-cmsy10") ||
- rFont.GetFamilyName().equalsIgnoreAsciiCase("jsMath-cmex10") ||
- rFont.GetFamilyName().equalsIgnoreAsciiCase("msam10") ||
- rFont.GetFamilyName().equalsIgnoreAsciiCase("msbm10") ||
- rFont.GetFamilyName().equalsIgnoreAsciiCase("wasy10") ||
- rFont.GetFamilyName().equalsIgnoreAsciiCase("Denemo") ||
- rFont.GetFamilyName().equalsIgnoreAsciiCase("GlyphBasic1") ||
- rFont.GetFamilyName().equalsIgnoreAsciiCase("GlyphBasic2") ||
- rFont.GetFamilyName().equalsIgnoreAsciiCase("GlyphBasic3") ||
- rFont.GetFamilyName().equalsIgnoreAsciiCase("GlyphBasic4") ||
- rFont.GetFamilyName().equalsIgnoreAsciiCase("Letters Laughing") ||
- rFont.GetFamilyName().equalsIgnoreAsciiCase("MusiQwik") ||
- rFont.GetFamilyName().equalsIgnoreAsciiCase("MusiSync") ||
- rFont.GetFamilyName().equalsIgnoreAsciiCase("stmary10") ||
- rFont.GetFamilyName().equalsIgnoreAsciiCase("Symbol") ||
- rFont.GetFamilyName().startsWith("STIXIntegrals") ||
- rFont.GetFamilyName().startsWith("STIXNonUnicode") ||
- rFont.GetFamilyName().startsWith("STIXSize") ||
- rFont.GetFamilyName().startsWith("STIXVariants") ||
+ rFont.GetName().equalsIgnoreAsciiCase("Apple Color Emoji") ||
+ rFont.GetName().equalsIgnoreAsciiCase("cmsy10") ||
+ rFont.GetName().equalsIgnoreAsciiCase("cmex10") ||
+ rFont.GetName().equalsIgnoreAsciiCase("esint10") ||
+ rFont.GetName().equalsIgnoreAsciiCase("feta26") ||
+ rFont.GetName().equalsIgnoreAsciiCase("jsMath-cmsy10") ||
+ rFont.GetName().equalsIgnoreAsciiCase("jsMath-cmex10") ||
+ rFont.GetName().equalsIgnoreAsciiCase("msam10") ||
+ rFont.GetName().equalsIgnoreAsciiCase("msbm10") ||
+ rFont.GetName().equalsIgnoreAsciiCase("wasy10") ||
+ rFont.GetName().equalsIgnoreAsciiCase("Denemo") ||
+ rFont.GetName().equalsIgnoreAsciiCase("GlyphBasic1") ||
+ rFont.GetName().equalsIgnoreAsciiCase("GlyphBasic2") ||
+ rFont.GetName().equalsIgnoreAsciiCase("GlyphBasic3") ||
+ rFont.GetName().equalsIgnoreAsciiCase("GlyphBasic4") ||
+ rFont.GetName().equalsIgnoreAsciiCase("Letters Laughing") ||
+ rFont.GetName().equalsIgnoreAsciiCase("MusiQwik") ||
+ rFont.GetName().equalsIgnoreAsciiCase("MusiSync") ||
+ rFont.GetName().equalsIgnoreAsciiCase("stmary10") ||
+ rFont.GetName().equalsIgnoreAsciiCase("Symbol") ||
+ rFont.GetName().startsWith("STIXIntegrals") ||
+ rFont.GetName().startsWith("STIXNonUnicode") ||
+ rFont.GetName().startsWith("STIXSize") ||
+ rFont.GetName().startsWith("STIXVariants") ||
isOpenSymbolFont(rFont);
}
bool canRenderNameOfSelectedFont(OutputDevice &rDevice)
{
const vcl::Font &rFont = rDevice.GetFont();
- return !isSymbolFont(rFont) && ( -1 == rDevice.HasGlyphs(rFont, rFont.GetFamilyName()) );
+ return !isSymbolFont(rFont) && ( -1 == rDevice.HasGlyphs(rFont, rFont.GetName()) );
}
OUString makeShortRepresentativeSymbolTextForSelectedFont(OutputDevice &rDevice)
{
- if (rDevice.GetFont().GetFamilyName() == "Symbol")
+ if (rDevice.GetFont().GetName() == "Symbol")
{
static const sal_Unicode aImplAppleSymbolText[] = {
0x03BC, 0x2202, 0x2211, 0x220F, 0x03C0, 0x222B, 0x03A9, 0x221A, 0};