sallayout.hxx (67e470da) sallayout.hxx (248a599f)
1/**************************************************************
2 *
3 * Licensed to the Apache Software Foundation (ASF) under one
4 * or more contributor license agreements. See the NOTICE file
5 * distributed with this work for additional information
6 * regarding copyright ownership. The ASF licenses this file
7 * to you under the Apache License, Version 2.0 (the
8 * "License"); you may not use this file except in compliance

--- 24 unchanged lines hidden (view full) ---

33#endif
34
35#include <vector>
36#include <list>
37#include <vcl/dllapi.h>
38
39// for typedef sal_UCS4
40#include <vcl/vclenum.hxx>
1/**************************************************************
2 *
3 * Licensed to the Apache Software Foundation (ASF) under one
4 * or more contributor license agreements. See the NOTICE file
5 * distributed with this work for additional information
6 * regarding copyright ownership. The ASF licenses this file
7 * to you under the Apache License, Version 2.0 (the
8 * "License"); you may not use this file except in compliance

--- 24 unchanged lines hidden (view full) ---

33#endif
34
35#include <vector>
36#include <list>
37#include <vcl/dllapi.h>
38
39// for typedef sal_UCS4
40#include <vcl/vclenum.hxx>
41#include "salglyphid.hxx"
41
42class SalGraphics;
43class ImplFontData;
44
45#define MAX_FALLBACK 16
46
47// ----------------
48// - LayoutOption -

--- 92 unchanged lines hidden (view full) ---

141// VCL_DLLPUBLIC sal_UCS4 GetMirroredChar( sal_UCS4 );
142sal_UCS4 GetLocalizedChar( sal_UCS4, LanguageType );
143VCL_PLUGIN_PUBLIC const char* GetAutofallback( sal_UCS4 ) ;
144
145// -------------
146// - SalLayout -
147// -------------
148
42
43class SalGraphics;
44class ImplFontData;
45
46#define MAX_FALLBACK 16
47
48// ----------------
49// - LayoutOption -

--- 92 unchanged lines hidden (view full) ---

142// VCL_DLLPUBLIC sal_UCS4 GetMirroredChar( sal_UCS4 );
143sal_UCS4 GetLocalizedChar( sal_UCS4, LanguageType );
144VCL_PLUGIN_PUBLIC const char* GetAutofallback( sal_UCS4 ) ;
145
146// -------------
147// - SalLayout -
148// -------------
149
149typedef sal_uInt32 sal_GlyphId;
150
151// Glyph Flags
152#define GF_NONE 0x00000000
153#define GF_FLAGMASK 0xFF800000
154#define GF_IDXMASK ~GF_FLAGMASK
155#define GF_ISCHAR 0x00800000
156#define GF_ROTL 0x01000000
157// caution !!!
158#define GF_VERT 0x02000000
159// GF_VERT is only for windows implementation
160// (win/source/gdi/salgdi3.cxx, win/source/gdi/winlayout.cxx)
161// don't use this elsewhere !!!
162#define GF_ROTR 0x03000000
163#define GF_ROTMASK 0x03000000
164#define GF_UNHINTED 0x04000000
165#define GF_GSUB 0x08000000
166#define GF_FONTMASK 0xF0000000
167#define GF_FONTSHIFT 28
168
169#define GF_DROPPED 0xFFFFFFFF
170
171// all positions/widths are in font units
172// one exception: drawposition is in pixel units
173
174class VCL_PLUGIN_PUBLIC SalLayout
175{
176public:
177 // used by upper layers
178 Point& DrawBase() { return maDrawBase; }

--- 122 unchanged lines hidden (view full) ---

301// --------------------
302
303struct GlyphItem
304{
305 int mnFlags;
306 int mnCharPos; // index in string
307 int mnOrigWidth; // original glyph width
308 int mnNewWidth; // width after adjustments
150// all positions/widths are in font units
151// one exception: drawposition is in pixel units
152
153class VCL_PLUGIN_PUBLIC SalLayout
154{
155public:
156 // used by upper layers
157 Point& DrawBase() { return maDrawBase; }

--- 122 unchanged lines hidden (view full) ---

280// --------------------
281
282struct GlyphItem
283{
284 int mnFlags;
285 int mnCharPos; // index in string
286 int mnOrigWidth; // original glyph width
287 int mnNewWidth; // width after adjustments
309 sal_GlyphId mnGlyphIndex;
288 sal_GlyphId maGlyphId;
310 Point maLinearPos; // absolute position of non rotated string
311
312public:
313 GlyphItem() {}
314
289 Point maLinearPos; // absolute position of non rotated string
290
291public:
292 GlyphItem() {}
293
315 GlyphItem( int nCharPos, sal_GlyphId nGlyphIndex, const Point& rLinearPos,
294 GlyphItem( int nCharPos, sal_GlyphId aGlyphId, const Point& rLinearPos,
316 long nFlags, int nOrigWidth )
317 : mnFlags(nFlags), mnCharPos(nCharPos),
318 mnOrigWidth(nOrigWidth), mnNewWidth(nOrigWidth),
295 long nFlags, int nOrigWidth )
296 : mnFlags(nFlags), mnCharPos(nCharPos),
297 mnOrigWidth(nOrigWidth), mnNewWidth(nOrigWidth),
319 mnGlyphIndex(nGlyphIndex), maLinearPos(rLinearPos)
298 maGlyphId(aGlyphId), maLinearPos(rLinearPos)
320 {}
321
322 enum{ FALLBACK_MASK=0xFF, IS_IN_CLUSTER=0x100, IS_RTL_GLYPH=0x200, IS_DIACRITIC=0x400 };
323
324 bool IsClusterStart() const { return ((mnFlags & IS_IN_CLUSTER) == 0); }
325 bool IsRTLGlyph() const { return ((mnFlags & IS_RTL_GLYPH) != 0); }
326 bool IsDiacritic() const { return ((mnFlags & IS_DIACRITIC) != 0); }
327};

--- 55 unchanged lines hidden ---
299 {}
300
301 enum{ FALLBACK_MASK=0xFF, IS_IN_CLUSTER=0x100, IS_RTL_GLYPH=0x200, IS_DIACRITIC=0x400 };
302
303 bool IsClusterStart() const { return ((mnFlags & IS_IN_CLUSTER) == 0); }
304 bool IsRTLGlyph() const { return ((mnFlags & IS_RTL_GLYPH) != 0); }
305 bool IsDiacritic() const { return ((mnFlags & IS_DIACRITIC) != 0); }
306};

--- 55 unchanged lines hidden ---