diff options
Diffstat (limited to 'vcl/unx/inc')
-rw-r--r-- | vcl/unx/inc/i18n_im.hxx | 4 | ||||
-rw-r--r-- | vcl/unx/inc/plugins/gtk/gtkobject.hxx | 1 | ||||
-rw-r--r-- | vcl/unx/inc/saldisp.hxx | 18 | ||||
-rw-r--r-- | vcl/unx/inc/salgdi.h | 24 | ||||
-rw-r--r-- | vcl/unx/inc/salobj.h | 1 | ||||
-rw-r--r-- | vcl/unx/inc/xfont.hxx | 162 |
6 files changed, 5 insertions, 205 deletions
diff --git a/vcl/unx/inc/i18n_im.hxx b/vcl/unx/inc/i18n_im.hxx index 297bc8edec17..a22a57b976c8 100644 --- a/vcl/unx/inc/i18n_im.hxx +++ b/vcl/unx/inc/i18n_im.hxx @@ -56,10 +56,6 @@ public: Bool FilterEvent( XEvent *pEvent, XLIB_Window window ); Bool AddConnectionWatch (Display *pDisplay, void *pConnectionHandler); - #ifdef _USE_PRINT_EXTENSION_ - void Invalidate() { mbUseable = False; } - #endif - SalI18N_InputMethod(); ~SalI18N_InputMethod(); }; diff --git a/vcl/unx/inc/plugins/gtk/gtkobject.hxx b/vcl/unx/inc/plugins/gtk/gtkobject.hxx index ea740249f1c6..9d3f235b8894 100644 --- a/vcl/unx/inc/plugins/gtk/gtkobject.hxx +++ b/vcl/unx/inc/plugins/gtk/gtkobject.hxx @@ -64,6 +64,7 @@ public: virtual const SystemEnvData* GetSystemData() const; + virtual void InterceptChildWindowKeyDown( sal_Bool bIntercept ); }; #endif // _SV_SALOBJ_H diff --git a/vcl/unx/inc/saldisp.hxx b/vcl/unx/inc/saldisp.hxx index 99c9bea699d6..89efad3cde4d 100644 --- a/vcl/unx/inc/saldisp.hxx +++ b/vcl/unx/inc/saldisp.hxx @@ -269,15 +269,10 @@ public: class SalI18N_InputMethod; class SalI18N_KeyboardExtension; -class XlfdStorage; -class ExtendedFontStruct; -class ExtendedXlfd; class AttributeProvider; class SalUnicodeConverter; class SalConverterCache; -DECLARE_LIST( SalFontCache, ExtendedFontStruct* ) - extern "C" { struct SnDisplay; struct SnLauncheeContext; @@ -349,8 +344,6 @@ protected: SalI18N_KeyboardExtension *mpKbdExtension; AttributeProvider *mpFactory; - XlfdStorage *mpFontList; - const ExtendedXlfd *mpFallbackFactory; Display *pDisp_; // X Display int m_nDefaultScreen; // XDefaultScreen @@ -374,8 +367,6 @@ protected: XLIB_Cursor aPointerCache_[POINTER_COUNT]; SalFrame* m_pCapture; - mutable SalFontCache* m_pFontCache; - // Keyboard BOOL bNumLockFromXS_; // Num Lock handled by X Server int nNumLockIndex_; // modifier index in modmap @@ -397,7 +388,6 @@ protected: mutable XLIB_Time m_nLastUserEventTime; // mutable because changed on first access - void DestroyFontCache(); virtual long Dispatch( XEvent *pEvent ) = 0; void InitXinerama(); void InitRandR( XLIB_Window aRoot ) const; @@ -434,14 +424,6 @@ public: void PrintEvent( const ByteString &rComment, XEvent *pEvent ) const; - XlfdStorage* GetXlfdList() const; - ExtendedFontStruct* - GetFont( const ExtendedXlfd *pFont, - const Size& rPixelSize, sal_Bool bVertical ) const; - const ExtendedXlfd* - GetFallbackFactory() - { return mpFallbackFactory; } - void Beep() const; void ModifierMapping(); diff --git a/vcl/unx/inc/salgdi.h b/vcl/unx/inc/salgdi.h index b5fdce50eee9..8af62a5c6607 100644 --- a/vcl/unx/inc/salgdi.h +++ b/vcl/unx/inc/salgdi.h @@ -28,18 +28,15 @@ #ifndef _SV_SALGDI_H #define _SV_SALGDI_H - -// -=-= exports -=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=- -class SalFontCacheItem; - // -=-= includes -=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-= #include "salstd.hxx" #include "vcl/salgdi.hxx" #include "vcl/salgtype.hxx" #include "tools/fract.hxx" #include "vcl/dllapi.h" +#include <vcl/vclenum.hxx> +#include <vcl/sallayout.hxx> #include <deque> -#include "xfont.hxx" // -=-= forwards -=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-= struct ImplFontMetricData; @@ -100,7 +97,6 @@ protected: Pixel nPenPixel_; GC pFontGC_; // Font attributes - ExtendedFontStructRef mXFont[ MAX_FALLBACK ]; ServerFont* mpServerFont[ MAX_FALLBACK ]; SalColor nTextColor_; @@ -185,7 +181,7 @@ protected: const SalBitmap &rTransparentBitmap, SalColor nTransparentColor ); - GC SelectFont(); + GC GetFontGC(); bool setFont( const ImplFontSelectData* pEntry, int nFallbackLevel ); void drawMaskedBitmap( const SalTwoRect* pPosAry, @@ -193,9 +189,6 @@ protected: const SalBitmap& rTransparentBitmap ); protected: - void DrawStringUCS2MB( ExtendedFontStruct& rFont, const Point&, - const sal_Unicode* pStr, int nLength ); - void DrawPrinterString( const SalLayout& ); void DrawServerFontString( const ServerFontLayout& ); @@ -386,19 +379,8 @@ inline Pixel X11SalGraphics::GetPixel( SalColor nSalColor ) const #ifdef DBG_UTIL #define stderr0( s ) fprintf( stderr, s ) -#define stderr1( s, a ) fprintf( stderr, s, a ) -#define stderr2( s, a, b ) fprintf( stderr, s, a, b ) -#define stderr3( s, a, b, c ) fprintf( stderr, s, a, b, c ) -#define stdass0( b ) (void)( !(b) \ - ? fprintf( stderr, "\"%s\" (%s line %d)\n", \ - #b, __FILE__, __LINE__ ) \ - : 0 ) #else #define stderr0( s ) ; -#define stderr1( s, a ) ; -#define stderr2( s, a, b ) ; -#define stderr3( s, a, b, c ) ; -#define stdass0( b ) ; #endif #endif // _SV_SALGDI_H diff --git a/vcl/unx/inc/salobj.h b/vcl/unx/inc/salobj.h index fa9f1309c8ca..d7d9334f281b 100644 --- a/vcl/unx/inc/salobj.h +++ b/vcl/unx/inc/salobj.h @@ -98,6 +98,7 @@ public: virtual const SystemEnvData* GetSystemData() const; + virtual void InterceptChildWindowKeyDown( sal_Bool bIntercept ); }; #endif // _SV_SALOBJ_H diff --git a/vcl/unx/inc/xfont.hxx b/vcl/unx/inc/xfont.hxx deleted file mode 100644 index 4041ed7ce67d..000000000000 --- a/vcl/unx/inc/xfont.hxx +++ /dev/null @@ -1,162 +0,0 @@ -/************************************************************************* - * - * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. - * - * Copyright 2000, 2010 Oracle and/or its affiliates. - * - * OpenOffice.org - a multi-platform office productivity suite - * - * This file is part of OpenOffice.org. - * - * OpenOffice.org is free software: you can redistribute it and/or modify - * it under the terms of the GNU Lesser General Public License version 3 - * only, as published by the Free Software Foundation. - * - * OpenOffice.org is distributed in the hope that it will be useful, - * but WITHOUT ANY WARRANTY; without even the implied warranty of - * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the - * GNU Lesser General Public License version 3 for more details - * (a copy is included in the LICENSE file that accompanied this code). - * - * You should have received a copy of the GNU Lesser General Public License - * version 3 along with OpenOffice.org. If not, see - * <http://www.openoffice.org/license.html> - * for a copy of the LGPLv3 License. - * - ************************************************************************/ -#ifndef EXTENDED_FONTSTRUCT_HXX -#define EXTENDED_FONTSTRUCT_HXX - -#ifndef _XLIB_H_ -#include <tools/prex.h> -#include <X11/Xlib.h> -#include <tools/postx.h> -#endif -#include <tools/ref.hxx> -#include <rtl/tencinfo.h> -#include <vcl/vclenum.hxx> -#include <vcl/sallayout.hxx> - -typedef unsigned short sal_MultiByte; - -class ImplFontMetricData; -class ExtendedXlfd; - -struct VerticalTextItem -{ - BOOL mbFixed; - XFontStruct* mpXFontStruct; - const sal_Unicode* mpString; - int mnLength; - int mnTransX; - int mnTransY; - int mnFixedAdvance; - int* mpAdvanceAry; - - VerticalTextItem( XFontStruct* pXFontStruct, - const sal_Unicode* pString, - int nLength, - int nTransX, - int nTransY, - int nFixedAdvance ) - : mbFixed( TRUE ), - mpXFontStruct( pXFontStruct ), - mpString( pString ), - mnLength( nLength ), - mnTransX( nTransX ), - mnTransY( nTransY ), - mnFixedAdvance( nFixedAdvance ) - {} - - VerticalTextItem( XFontStruct* pXFontStruct, - const sal_Unicode* pString, - int nLength, - int nTransX, - int nTransY, - int* pAdvanceAry ) - : mbFixed( FALSE ), - mpXFontStruct( pXFontStruct ), - mpString( pString ), - mnLength( nLength ), - mnTransX( nTransX ), - mnTransY( nTransY ), - mpAdvanceAry( pAdvanceAry ) - {} - - ~VerticalTextItem() - { - if (!mbFixed) - { - delete( mpAdvanceAry ); - } - } -}; - -class ExtendedFontStruct : public SvRefBase -{ - private: - Display* mpDisplay; - Size maPixelSize; - float mfXScale; - float mfYScale; - sal_Size mnDefaultWidth; - sal_Bool mbVertical; - rtl_TextEncoding mnCachedEncoding; - rtl_TextEncoding mnAsciiEncoding; - - ExtendedXlfd* mpXlfd; - XFontStruct** mpXFontStruct; - - // unicode range cache - mutable sal_uInt32* mpRangeCodes; - mutable int mnRangeCount; - - int LoadEncoding( rtl_TextEncoding nEncoding ); - FontPitch GetSpacing( rtl_TextEncoding nEncoding ); - bool GetFontBoundingBox( XCharStruct *pCharStruct, - int *pAscent, int *pDescent ) ; - - sal_Size GetDefaultWidth(); - sal_Size GetCharWidth8( sal_Unicode nFrom, sal_Unicode nTo, - sal_Int32 *pWidthArray, - rtl_TextEncoding nEncoding ); - sal_Size GetCharWidthUTF16( sal_Unicode nFrom, sal_Unicode nTo, - sal_Int32 *pWidthArray ); - sal_Size GetCharWidth16( sal_Unicode nFrom, sal_Unicode nTo, - sal_Int32 *pWidthArray, ExtendedFontStruct *pFallback ); - public: - ExtendedFontStruct( Display* pDisplay, - const Size& rPixelSize, sal_Bool bVertical, - ExtendedXlfd* pXlfd ); - ~ExtendedFontStruct(); - bool Match( const ExtendedXlfd *pXlfd, - const Size& rPixelSize, sal_Bool bVertical ) const; - XFontStruct* GetFontStruct( rtl_TextEncoding nEncoding ); - XFontStruct* GetFontStruct( sal_Unicode nChar, - rtl_TextEncoding *pEncoding ); - bool ToImplFontMetricData( ImplFontMetricData *pMetric ); - rtl_TextEncoding GetAsciiEncoding( int *pAsciiRange = NULL ) const; - sal_Size GetCharWidth( sal_Unicode, - sal_Int32* pPhysWidth, sal_Int32* pLogWidth ); - int GetFontCodeRanges( sal_uInt32* pCodePairs ) const; - bool HasUnicodeChar( sal_Unicode ) const; -}; - -// Declaration and Implementation for ExtendedFontStructRef: Add RefCounting -// to ExtendedFontStruct (it's not possible to separate decl and impl into -// a separate source file: all ref member functions are inline -SV_DECL_IMPL_REF( ExtendedFontStruct ); - -class X11FontLayout : public GenericSalLayout -{ -public: - X11FontLayout( ExtendedFontStruct& ); - virtual bool LayoutText( ImplLayoutArgs& ); - virtual void AdjustLayout( ImplLayoutArgs& ); - virtual void DrawText( SalGraphics& ) const; - -private: - ExtendedFontStruct& mrFont; -}; - -#endif /* EXTENDED_FONTSTRUCT_HXX */ |