diff options
Diffstat (limited to 'vcl/unx')
-rw-r--r-- | vcl/unx/generic/app/i18n_ic.cxx | 6 | ||||
-rw-r--r-- | vcl/unx/generic/app/i18n_im.cxx | 8 | ||||
-rw-r--r-- | vcl/unx/generic/app/randrwrapper.cxx | 9 | ||||
-rw-r--r-- | vcl/unx/generic/app/saldisp.cxx | 8 | ||||
-rw-r--r-- | vcl/unx/generic/fontmanager/fontconfig.cxx | 11 | ||||
-rw-r--r-- | vcl/unx/generic/fontmanager/fontmanager.cxx | 5 | ||||
-rw-r--r-- | vcl/unx/generic/gdi/salgdi2.cxx | 4 | ||||
-rw-r--r-- | vcl/unx/generic/glyphs/freetype_glyphcache.cxx | 16 | ||||
-rw-r--r-- | vcl/unx/generic/print/common_gfx.cxx | 11 | ||||
-rw-r--r-- | vcl/unx/generic/print/genprnpsp.cxx | 5 | ||||
-rw-r--r-- | vcl/unx/generic/print/glyphset.cxx | 18 | ||||
-rw-r--r-- | vcl/unx/generic/print/glyphset.hxx | 4 | ||||
-rw-r--r-- | vcl/unx/generic/print/printerjob.cxx | 7 | ||||
-rw-r--r-- | vcl/unx/generic/print/text_gfx.cxx | 5 | ||||
-rw-r--r-- | vcl/unx/gtk/fpicker/SalGtkFilePicker.cxx | 7 |
15 files changed, 43 insertions, 81 deletions
diff --git a/vcl/unx/generic/app/i18n_ic.cxx b/vcl/unx/generic/app/i18n_ic.cxx index df63ead54078..a0ce0daeb902 100644 --- a/vcl/unx/generic/app/i18n_ic.cxx +++ b/vcl/unx/generic/app/i18n_ic.cxx @@ -523,11 +523,11 @@ SalI18N_InputContext::SupportInputMethodStyle( XIMStyles *pIMStyles ) // handle extended and normal key input -int +void SalI18N_InputContext::CommitKeyEvent(sal_Unicode* pText, sal_Size nLength) { if (nLength == 1 && IsControlCode(pText[0])) - return 0; + return; if( maClientData.pFrame ) { @@ -547,8 +547,6 @@ SalI18N_InputContext::CommitKeyEvent(sal_Unicode* pText, sal_Size nLength) else fprintf(stderr, "CommitKeyEvent without frame\n" ); #endif - - return 0; } int diff --git a/vcl/unx/generic/app/i18n_im.cxx b/vcl/unx/generic/app/i18n_im.cxx index 61e3bf533cf1..321832b1b27a 100644 --- a/vcl/unx/generic/app/i18n_im.cxx +++ b/vcl/unx/generic/app/i18n_im.cxx @@ -195,7 +195,7 @@ IsXWindowCompatibleLocale( const char* p_locale ) // see i8988, i9188, i8930, i16318 // on Solaris the environment needs to be set equivalent to the locale (#i37047#) -bool +void SalI18N_InputMethod::SetLocale( const char* pLocale ) { // check whether we want an Input Method engine, if we don't we @@ -229,8 +229,6 @@ SalI18N_InputMethod::SetLocale( const char* pLocale ) mbUseable = False; } } - - return mbUseable; } Bool @@ -331,7 +329,7 @@ PrintInputStyle( XIMStyles *pStyle ) // this is the real constructing routine, since locale setting has to be done // prior to xopendisplay, the xopenim call has to be delayed -bool +void SalI18N_InputMethod::CreateMethod ( Display *pDisplay ) { if ( mbUseable ) @@ -371,8 +369,6 @@ SalI18N_InputMethod::CreateMethod ( Display *pDisplay ) maDestroyCallback.client_data = reinterpret_cast<XPointer>(this); if (mbUseable && maMethod != nullptr) XSetIMValues(maMethod, XNDestroyCallback, &maDestroyCallback, nullptr); - - return mbUseable; } // give IM the opportunity to look at the event, and possibly hide it diff --git a/vcl/unx/generic/app/randrwrapper.cxx b/vcl/unx/generic/app/randrwrapper.cxx index 3e899e8c05a0..570cfcc9dc4b 100644 --- a/vcl/unx/generic/app/randrwrapper.cxx +++ b/vcl/unx/generic/app/randrwrapper.cxx @@ -279,10 +279,10 @@ void SalDisplay::DeInitRandR() #endif } -int SalDisplay::processRandREvent( XEvent* pEvent ) +void SalDisplay::processRandREvent( XEvent* pEvent ) { +#ifdef USE_RANDR int nRet = 0; - #ifdef USE_RANDR XConfigureEvent* pCnfEvent=reinterpret_cast<XConfigureEvent*>(pEvent); if( m_bUseRandRWrapper && pWrapper && pWrapper->XRRRootToScreen(GetDisplay(),pCnfEvent->window) != -1 ) { @@ -323,11 +323,10 @@ int SalDisplay::processRandREvent( XEvent* pEvent ) emitDisplayChanged(); } } - #else +#else (void)this; (void)pEvent; - #endif - return nRet; +#endif } /* vim:set shiftwidth=4 softtabstop=4 expandtab: */ diff --git a/vcl/unx/generic/app/saldisp.cxx b/vcl/unx/generic/app/saldisp.cxx index 02efd278e573..8f8f92ed7bd7 100644 --- a/vcl/unx/generic/app/saldisp.cxx +++ b/vcl/unx/generic/app/saldisp.cxx @@ -1886,10 +1886,10 @@ bool SalX11Display::IsEvent() return false; } -bool SalX11Display::Yield() +void SalX11Display::Yield() { if( DispatchInternalEvent() ) - return true; + return; XEvent aEvent; DBG_ASSERT( static_cast<SalYieldMutex*>(GetSalData()->m_pInstance->GetYieldMutex())->GetThreadId() == @@ -1899,7 +1899,7 @@ bool SalX11Display::Yield() XNextEvent( pDisp_, &aEvent ); // FIXME: under-convinced by Dispatch boolean return value vs. salframe. - bool bProcessedEvent = Dispatch( &aEvent ); + Dispatch( &aEvent ); #ifdef DBG_UTIL if( GetX11SalData()->HasXErrorOccurred() ) @@ -1909,8 +1909,6 @@ bool SalX11Display::Yield() } #endif GetX11SalData()->ResetXErrorOccurred(); - - return bProcessedEvent; } bool SalX11Display::Dispatch( XEvent *pEvent ) diff --git a/vcl/unx/generic/fontmanager/fontconfig.cxx b/vcl/unx/generic/fontmanager/fontconfig.cxx index 611a2edf1a16..eb1582298103 100644 --- a/vcl/unx/generic/fontmanager/fontconfig.cxx +++ b/vcl/unx/generic/fontmanager/fontconfig.cxx @@ -944,7 +944,7 @@ IMPL_LINK_NOARG_TYPED(PrintFontManager, autoInstallFontLangSupport, Timer *, voi } #endif -bool PrintFontManager::Substitute( FontSelectPattern &rPattern, OUString& rMissingCodes ) +void PrintFontManager::Substitute( FontSelectPattern &rPattern, OUString& rMissingCodes ) { bool bRet = false; @@ -1136,8 +1136,6 @@ bool PrintFontManager::Substitute( FontSelectPattern &rPattern, OUString& rMissi FcFontSetDestroy( pSet ); } - - return bRet; } FontConfigFontOptions::~FontConfigFontOptions() @@ -1231,7 +1229,7 @@ FontConfigFontOptions* PrintFontManager::getFontOptions( return pOptions; } -bool PrintFontManager::matchFont( FastPrintFontInfo& rInfo, const css::lang::Locale& rLocale ) +void PrintFontManager::matchFont( FastPrintFontInfo& rInfo, const css::lang::Locale& rLocale ) { FontCfgWrapper& rWrapper = FontCfgWrapper::get(); @@ -1255,7 +1253,6 @@ bool PrintFontManager::matchFont( FastPrintFontInfo& rInfo, const css::lang::Loc FcResult eResult = FcResultNoMatch; FcFontSet *pFontSet = rWrapper.getFontSet(); FcPattern* pResult = FcFontSetMatch(pConfig, &pFontSet, 1, pPattern, &eResult); - bool bSuccess = false; if( pResult ) { FcFontSet* pSet = FcFontSetCreate(); @@ -1276,7 +1273,7 @@ bool PrintFontManager::matchFont( FastPrintFontInfo& rInfo, const css::lang::Loc int nDirID = getDirectoryAtom( aDir, true ); fontID aFont = findFontFileID( nDirID, aBase, nCollectionEntry ); if( aFont > 0 ) - bSuccess = getFontFastInfo( aFont, rInfo ); + getFontFastInfo( aFont, rInfo ); } } // info: destroying the pSet destroys pResult implicitly @@ -1286,8 +1283,6 @@ bool PrintFontManager::matchFont( FastPrintFontInfo& rInfo, const css::lang::Loc // cleanup FcPatternDestroy( pPattern ); - - return bSuccess; } /* vim:set shiftwidth=4 softtabstop=4 expandtab: */ diff --git a/vcl/unx/generic/fontmanager/fontmanager.cxx b/vcl/unx/generic/fontmanager/fontmanager.cxx index 1b895c805ad5..102375016f80 100644 --- a/vcl/unx/generic/fontmanager/fontmanager.cxx +++ b/vcl/unx/generic/fontmanager/fontmanager.cxx @@ -1584,9 +1584,8 @@ bool PrintFontManager::getFontFastInfo( fontID nFontID, FastPrintFontInfo& rInfo return pFont != nullptr; } -bool PrintFontManager::getFontBoundingBox( fontID nFontID, int& xMin, int& yMin, int& xMax, int& yMax ) +void PrintFontManager::getFontBoundingBox( fontID nFontID, int& xMin, int& yMin, int& xMax, int& yMax ) { - bool bSuccess = false; PrintFont* pFont = getFont( nFontID ); if( pFont ) { @@ -1598,13 +1597,11 @@ bool PrintFontManager::getFontBoundingBox( fontID nFontID, int& xMin, int& yMin, else if( pFont->m_eType == fonttype::TrueType ) analyzeTrueTypeFile( pFont ); } - bSuccess = true; xMin = pFont->m_nXMin; yMin = pFont->m_nYMin; xMax = pFont->m_nXMax; yMax = pFont->m_nYMax; } - return bSuccess; } int PrintFontManager::getFontFaceNumber( fontID nFontID ) const diff --git a/vcl/unx/generic/gdi/salgdi2.cxx b/vcl/unx/generic/gdi/salgdi2.cxx index 456d1467d05a..0ac44aae0e67 100644 --- a/vcl/unx/generic/gdi/salgdi2.cxx +++ b/vcl/unx/generic/gdi/salgdi2.cxx @@ -76,10 +76,10 @@ void X11SalGraphics::CopyScreenArea( Display* pDisplay, } } -bool X11SalGraphics::FillPixmapFromScreen( X11Pixmap* pPixmap, int nX, int nY ) +void X11SalGraphics::FillPixmapFromScreen( X11Pixmap* pPixmap, int nX, int nY ) { X11GraphicsImpl& rImpl = dynamic_cast<X11GraphicsImpl&>(*mxImpl.get()); - return rImpl.FillPixmapFromScreen( pPixmap, nX, nY ); + rImpl.FillPixmapFromScreen( pPixmap, nX, nY ); } bool X11SalGraphics::RenderPixmapToScreen( X11Pixmap* pPixmap, X11Pixmap* pMask, int nX, int nY ) diff --git a/vcl/unx/generic/glyphs/freetype_glyphcache.cxx b/vcl/unx/generic/glyphs/freetype_glyphcache.cxx index 957450f2b066..3bb5055ac2db 100644 --- a/vcl/unx/generic/glyphs/freetype_glyphcache.cxx +++ b/vcl/unx/generic/glyphs/freetype_glyphcache.cxx @@ -747,13 +747,13 @@ static inline void SplitGlyphFlags( const ServerFont& rFont, sal_GlyphId& rGlyph rGlyphId = rFont.GetRawGlyphIndex( rGlyphId ); } -int ServerFont::ApplyGlyphTransform( int nGlyphFlags, +void ServerFont::ApplyGlyphTransform( int nGlyphFlags, FT_Glyph pGlyphFT, bool bForBitmapProcessing ) const { int nAngle = GetFontSelData().mnOrientation; // shortcut most common case if( !nAngle && !nGlyphFlags ) - return nAngle; + return; const FT_Size_Metrics& rMetrics = maFaceFT->size->metrics; FT_Vector aVector; @@ -816,8 +816,6 @@ int ServerFont::ApplyGlyphTransform( int nGlyphFlags, pBmpGlyphFT->left += (aVector.x + 32) >> 6; pBmpGlyphFT->top += (aVector.y + 32) >> 6; } - - return nAngle; } sal_GlyphId ServerFont::GetRawGlyphIndex(sal_UCS4 aChar, sal_UCS4 aVS) const @@ -1303,7 +1301,7 @@ bool ServerFont::GetGlyphOutline( sal_GlyphId aGlyphId, return true; } -bool ServerFont::ApplyGSUB( const FontSelectPattern& rFSD ) +void ServerFont::ApplyGSUB( const FontSelectPattern& rFSD ) { #define MKTAG(s) ((((((s[0]<<8)+s[1])<<8)+s[2])<<8)+s[3]) @@ -1314,13 +1312,13 @@ bool ServerFont::ApplyGSUB( const FontSelectPattern& rFSD ) // TODO: request more features depending on script and language system if( aReqFeatureTagList.empty()) // nothing to do - return true; + return; // load GSUB table into memory sal_uLong nLength = 0; const FT_Byte* const pGsubBase = mpFontInfo->GetTable( "GSUB", &nLength ); if( !pGsubBase ) - return false; + return; // parse GSUB header const FT_Byte* pGsubHeader = pGsubBase; @@ -1383,7 +1381,7 @@ bool ServerFont::ApplyGSUB( const FontSelectPattern& rFSD ) } if( aFeatureIndexList.empty() ) - return true; + return; UshortList aLookupIndexList; UshortList aLookupOffsetList; @@ -1530,8 +1528,6 @@ bool ServerFont::ApplyGSUB( const FontSelectPattern& rFSD ) maGlyphSubstitution[ (*it).first ] = (*it).second; } } - - return true; } const unsigned char* ServerFont::GetTable(const char* pName, sal_uLong* pLength) diff --git a/vcl/unx/generic/print/common_gfx.cxx b/vcl/unx/generic/print/common_gfx.cxx index 105de9713b58..52387c97fc32 100644 --- a/vcl/unx/generic/print/common_gfx.cxx +++ b/vcl/unx/generic/print/common_gfx.cxx @@ -52,7 +52,7 @@ GraphicsStatus::GraphicsStatus() : * non graphics graphics routines */ -bool +void PrinterGfx::Init (PrinterJob &rPrinterJob) { mpPageHeader = rPrinterJob.GetCurrentPageHeader (); @@ -65,11 +65,9 @@ PrinterGfx::Init (PrinterJob &rPrinterJob) rPrinterJob.GetScale (mfScaleX, mfScaleY); const PrinterInfo& rInfo( PrinterInfoManager::get().getPrinterInfo( rPrinterJob.GetPrinterName() ) ); mbUploadPS42Fonts = rInfo.m_pParser && rInfo.m_pParser->isType42Capable(); - - return true; } -bool +void PrinterGfx::Init (const JobData& rData) { mpPageHeader = nullptr; @@ -83,8 +81,6 @@ PrinterGfx::Init (const JobData& rData) mfScaleY = (double)72.0 / (double)mnDpi; const PrinterInfo& rInfo( PrinterInfoManager::get().getPrinterInfo( rData.m_aPrinterName ) ); mbUploadPS42Fonts = rInfo.m_pParser && rInfo.m_pParser->isType42Capable(); - - return true; } @@ -163,12 +159,11 @@ PrinterGfx::BeginSetClipRegion( sal_uInt32 ) maClipRegion.clear(); } -bool +void PrinterGfx::UnionClipRegion (sal_Int32 nX,sal_Int32 nY,sal_Int32 nDX,sal_Int32 nDY) { if( nDX && nDY ) maClipRegion.push_back (Rectangle(Point(nX,nY ), Size(nDX,nDY))); - return true; } bool diff --git a/vcl/unx/generic/print/genprnpsp.cxx b/vcl/unx/generic/print/genprnpsp.cxx index 4e704543d418..521c5f0d17cd 100644 --- a/vcl/unx/generic/print/genprnpsp.cxx +++ b/vcl/unx/generic/print/genprnpsp.cxx @@ -973,12 +973,11 @@ SalGraphics* PspSalPrinter::StartPage( ImplJobSetup* pJobSetup, bool ) return m_pGraphics; } -bool PspSalPrinter::EndPage() +void PspSalPrinter::EndPage() { - bool bResult = m_aPrintJob.EndPage(); + m_aPrintJob.EndPage(); m_aPrinterGfx.Clear(); OSL_TRACE("PspSalPrinter::EndPage"); - return bResult; } sal_uLong PspSalPrinter::GetErrorCode() diff --git a/vcl/unx/generic/print/glyphset.cxx b/vcl/unx/generic/print/glyphset.cxx index d75d9420d9f2..72fc2fa12294 100644 --- a/vcl/unx/generic/print/glyphset.cxx +++ b/vcl/unx/generic/print/glyphset.cxx @@ -592,14 +592,14 @@ GlyphSet::ImplDrawText (PrinterGfx &rGfx, const Point& rPoint, DrawGlyphs( rGfx, rPoint, nullptr, pStr, nLen, pDeltaArray, false); } -bool +void GlyphSet::PSUploadEncoding(osl::File* pOutFile, PrinterGfx &rGfx) { // only for ps fonts if (meBaseType != fonttype::Type1) - return false; + return; if (mnBaseEncoding == RTL_TEXTENCODING_SYMBOL) - return false; + return; PrintFontManager &rMgr = rGfx.GetFontMgr(); @@ -676,8 +676,6 @@ GlyphSet::PSUploadEncoding(osl::File* pOutFile, PrinterGfx &rGfx) PSDefineReencodedFont (pOutFile, nGlyphSetID); } - - return true; } struct EncEntry @@ -727,12 +725,12 @@ static void CreatePSUploadableFont( TrueTypeFont* pSrcFont, FILE* pTmpFile, &aRequestedGlyphs[0], &aEncoding[0], nGlyphCount ); } -bool +void GlyphSet::PSUploadFont (osl::File& rOutFile, PrinterGfx &rGfx, bool bAllowType42, std::list< OString >& rSuppliedFonts ) { // only for truetype fonts if (meBaseType != fonttype::TrueType) - return false; + return; #if defined( UNX ) TrueTypeFont *pTTFont; @@ -740,13 +738,13 @@ GlyphSet::PSUploadFont (osl::File& rOutFile, PrinterGfx &rGfx, bool bAllowType42 int nFace = rGfx.GetFontMgr().getFontFaceNumber(mnFontID); sal_Int32 nSuccess = OpenTTFontFile(aTTFileName.getStr(), nFace, &pTTFont); if (nSuccess != SF_OK) - return false; + return; utl::TempFile aTmpFile; aTmpFile.EnableKillingFile(); FILE* pTmpFile = fopen(OUStringToOString(aTmpFile.GetFileName(), osl_getThreadTextEncoding()).getStr(), "w+b"); if (pTmpFile == nullptr) - return false; + return; // array of unicode source characters sal_uInt16 pUChars[256]; @@ -836,11 +834,9 @@ GlyphSet::PSUploadFont (osl::File& rOutFile, PrinterGfx &rGfx, bool bAllowType42 CloseTTFont (pTTFont); fclose (pTmpFile); - return true; #else (void)rOutFile; (void)rGfx; (void)bAllowType42; (void)rSuppliedFonts; # warning FIXME: Missing OpenTTFontFile outside of Unix ... - return false; #endif } diff --git a/vcl/unx/generic/print/glyphset.hxx b/vcl/unx/generic/print/glyphset.hxx index 04f8f21a099f..c35ac42730ac 100644 --- a/vcl/unx/generic/print/glyphset.hxx +++ b/vcl/unx/generic/print/glyphset.hxx @@ -114,8 +114,8 @@ public: sal_Int16 nLen, const sal_Int32* pDeltaArray, bool bUseGlyphs=true); - bool PSUploadEncoding(osl::File* pOutFile, PrinterGfx &rGfx); - bool PSUploadFont (osl::File& rOutFile, PrinterGfx &rGfx, bool bAsType42, std::list< OString >& rSuppliedFonts ); + void PSUploadEncoding(osl::File* pOutFile, PrinterGfx &rGfx); + void PSUploadFont (osl::File& rOutFile, PrinterGfx &rGfx, bool bAsType42, std::list< OString >& rSuppliedFonts ); }; } /* namespace psp */ diff --git a/vcl/unx/generic/print/printerjob.cxx b/vcl/unx/generic/print/printerjob.cxx index 746ceed6aca2..4675ef7d8e89 100644 --- a/vcl/unx/generic/print/printerjob.cxx +++ b/vcl/unx/generic/print/printerjob.cxx @@ -579,7 +579,7 @@ PrinterJob::InitPaperSize (const JobData& rJobSetup) mfYScale = -1.0 * (double)72.0 / (double)mnResolution; } -bool +void PrinterJob::StartPage (const JobData& rJobSetup) { InitPaperSize (rJobSetup); @@ -594,7 +594,7 @@ PrinterJob::StartPage (const JobData& rJobSetup) maPageList.push_back (pPageBody); if( ! (pPageHeader && pPageBody) ) - return false; + return; // write page header according to Document Structuring Conventions (DSC) WritePS (pPageHeader, "%%Page: "); @@ -644,10 +644,7 @@ PrinterJob::StartPage (const JobData& rJobSetup) if ( writePageSetup( pPageHeader, rJobSetup, bWriteFeatures ) ) { m_aLastJobData = rJobSetup; - return true; } - - return false; } bool diff --git a/vcl/unx/generic/print/text_gfx.cxx b/vcl/unx/generic/print/text_gfx.cxx index cfe4b8c5ca7a..d7a5995eeeee 100644 --- a/vcl/unx/generic/print/text_gfx.cxx +++ b/vcl/unx/generic/print/text_gfx.cxx @@ -426,7 +426,7 @@ PrinterGfx::DrawText ( ); } -bool PrinterGfx::drawVerticalizedText( +void PrinterGfx::drawVerticalizedText( const Point& rPoint, const sal_Unicode* pStr, sal_Int16 nLen, @@ -436,7 +436,7 @@ bool PrinterGfx::drawVerticalizedText( PrintFontManager &rMgr = PrintFontManager::get(); PrintFontInfo aInfo; if (!rMgr.getFontInfo(mnFontID, aInfo)) - return false; + return; sal_Int32* pDelta = static_cast<sal_Int32*>(alloca( nLen * sizeof(sal_Int32) )); @@ -521,7 +521,6 @@ bool PrinterGfx::drawVerticalizedText( nLastPos = i; } mnTextAngle = nNormalAngle; - return true; } void diff --git a/vcl/unx/gtk/fpicker/SalGtkFilePicker.cxx b/vcl/unx/gtk/fpicker/SalGtkFilePicker.cxx index cee8543f4adb..67a16c7d69d3 100644 --- a/vcl/unx/gtk/fpicker/SalGtkFilePicker.cxx +++ b/vcl/unx/gtk/fpicker/SalGtkFilePicker.cxx @@ -343,10 +343,8 @@ public: bool hasSubFilters( ) const; /** retrieves the filters belonging to the entry - @return - the number of sub filters */ - sal_Int32 getSubFilters( css::uno::Sequence< css::beans::StringPair >& _rSubFilterList ); + void getSubFilters( css::uno::Sequence< css::beans::StringPair >& _rSubFilterList ); // helpers for iterating the sub filters const css::beans::StringPair* beginSubFilters() const { return m_aSubFilters.getConstArray(); } @@ -358,10 +356,9 @@ bool FilterEntry::hasSubFilters() const return( 0 < m_aSubFilters.getLength() ); } -sal_Int32 FilterEntry::getSubFilters( css::uno::Sequence< css::beans::StringPair >& _rSubFilterList ) +void FilterEntry::getSubFilters( css::uno::Sequence< css::beans::StringPair >& _rSubFilterList ) { _rSubFilterList = m_aSubFilters; - return m_aSubFilters.getLength(); } static bool |