1d1766043SAndrew Rist/************************************************************** 2d1766043SAndrew Rist * 3d1766043SAndrew Rist * Licensed to the Apache Software Foundation (ASF) under one 4d1766043SAndrew Rist * or more contributor license agreements. See the NOTICE file 5d1766043SAndrew Rist * distributed with this work for additional information 6d1766043SAndrew Rist * regarding copyright ownership. The ASF licenses this file 7d1766043SAndrew Rist * to you under the Apache License, Version 2.0 (the 8d1766043SAndrew Rist * "License"); you may not use this file except in compliance 9d1766043SAndrew Rist * with the License. You may obtain a copy of the License at 10d1766043SAndrew Rist * 11d1766043SAndrew Rist * http://www.apache.org/licenses/LICENSE-2.0 12d1766043SAndrew Rist * 13d1766043SAndrew Rist * Unless required by applicable law or agreed to in writing, 14d1766043SAndrew Rist * software distributed under the License is distributed on an 15d1766043SAndrew Rist * "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY 16d1766043SAndrew Rist * KIND, either express or implied. See the License for the 17d1766043SAndrew Rist * specific language governing permissions and limitations 18d1766043SAndrew Rist * under the License. 19d1766043SAndrew Rist * 20d1766043SAndrew Rist *************************************************************/ 21d1766043SAndrew Rist 22d1766043SAndrew Rist 23cdf0e10cSrcweir#ifndef __com_sun_star_rendering_FontRequest_idl__ 24cdf0e10cSrcweir#define __com_sun_star_rendering_FontRequest_idl__ 25cdf0e10cSrcweir 26cdf0e10cSrcweir#ifndef __com_sun_star_rendering_FontInfo_idl__ 27cdf0e10cSrcweir#include <com/sun/star/rendering/FontInfo.idl> 28cdf0e10cSrcweir#endif 29cdf0e10cSrcweir 30cdf0e10cSrcweir#ifndef __com_sun_star_lang_Locale_idl__ 31cdf0e10cSrcweir#include <com/sun/star/lang/Locale.idl> 32cdf0e10cSrcweir#endif 33cdf0e10cSrcweir 34cdf0e10cSrcweirmodule com { module sun { module star { module rendering { 35cdf0e10cSrcweir 36cdf0e10cSrcweir/** This structure contains all information necessary to describe a 37cdf0e10cSrcweir font to be queried from XCanvas.<p> 38cdf0e10cSrcweir 39cdf0e10cSrcweir Note: Outline fonts are to be requested as a special family, set 40cdf0e10cSrcweir <member>FontInfo::FamilyName</member> appropriately. Emboss/relief 41cdf0e10cSrcweir must be emulated by upper layers.<p> 42cdf0e10cSrcweir 43cdf0e10cSrcweir Leave the <member>FontInfo::FamilyName</member> and 44cdf0e10cSrcweir <member>FontInfo::StyleName</member> empty, if font selection 45cdf0e10cSrcweir should only happen via the PANOSE description. 46cdf0e10cSrcweir 47*d695a2a0SJürgen Schmidt @since OpenOffice 2.0 48cdf0e10cSrcweir */ 49cdf0e10cSrcweirpublished struct FontRequest 50cdf0e10cSrcweir{ 51cdf0e10cSrcweir /** The description of the font.<p> 52cdf0e10cSrcweir 53cdf0e10cSrcweir This member contains the description of the font as returned 54cdf0e10cSrcweir by the font listing methods.<p> 55cdf0e10cSrcweir */ 56cdf0e10cSrcweir FontInfo FontDescription; 57cdf0e10cSrcweir 58cdf0e10cSrcweir //------------------------------------------------------------------------- 59cdf0e10cSrcweir 60cdf0e10cSrcweir /** The size of the font in <em>device</em> coordinate space.<p> 61cdf0e10cSrcweir 62cdf0e10cSrcweir This value corresponds to the font height in Western scripts, 63cdf0e10cSrcweir but is independent of the writing direction (see 64cdf0e10cSrcweir <member>FontRequest::IsVertical</member> below). That 65cdf0e10cSrcweir means, the value specified here is always measured orthogonal 66cdf0e10cSrcweir to the text advancement (height for horizontal writing, and 67cdf0e10cSrcweir width for vertical writing).<p> 68cdf0e10cSrcweir 69cdf0e10cSrcweir When this value is negative, its absolute value is taken as 70cdf0e10cSrcweir the character size of the font. If this value is positive, 71cdf0e10cSrcweir it's taken as the cell size of the font.<p> 72cdf0e10cSrcweir 73cdf0e10cSrcweir This member and the referenceAdvancement member are mutually 74cdf0e10cSrcweir exclusive, one of them has to be set to 0 (which means don't 75cdf0e10cSrcweir care).<p> 76cdf0e10cSrcweir 77cdf0e10cSrcweir For distorted fonts, the render transformation must be 78cdf0e10cSrcweir used. That is, the size specified here corresponds to device 79cdf0e10cSrcweir pixel only if the combined render transformation during text 80cdf0e10cSrcweir output equals the identity transform. This also applies to all 81cdf0e10cSrcweir query methods, for both <type>XCanvasFont</type> and 82cdf0e10cSrcweir <type>XTextLayout</type>.<p> 83cdf0e10cSrcweir */ 84cdf0e10cSrcweir double CellSize; 85cdf0e10cSrcweir 86cdf0e10cSrcweir //------------------------------------------------------------------------- 87cdf0e10cSrcweir 88cdf0e10cSrcweir /** This value specifies the size of the font in the writing 89cdf0e10cSrcweir direction (i.e. width for horizontal writing, and height for 90cdf0e10cSrcweir vertical writing).<p> 91cdf0e10cSrcweir 92cdf0e10cSrcweir It is equivalent to the referenceCharSize of the FontMetrics 93cdf0e10cSrcweir structure.<p> 94cdf0e10cSrcweir 95cdf0e10cSrcweir This member and the cellSize member are mutually exclusive, 96cdf0e10cSrcweir one of them has to be set to 0 (which means don't care). For 97cdf0e10cSrcweir distorted fonts, the font matrix must be used.<p> 98cdf0e10cSrcweir */ 99cdf0e10cSrcweir double ReferenceAdvancement; 100cdf0e10cSrcweir 101cdf0e10cSrcweir //------------------------------------------------------------------------- 102cdf0e10cSrcweir 103cdf0e10cSrcweir /** The locale this font should be able to render.<p> 104cdf0e10cSrcweir 105cdf0e10cSrcweir This member supplements the 106cdf0e10cSrcweir <member>FontInfo::UnicodeRange0</member> entry with a specific 107cdf0e10cSrcweir locale; this is e.g. important when selecting between 108cdf0e10cSrcweir traditional and simplified chinese is necessary (since the 109cdf0e10cSrcweir letters have the same unicode ranges and character values).<p> 110cdf0e10cSrcweir */ 111cdf0e10cSrcweir ::com::sun::star::lang::Locale Locale; 112cdf0e10cSrcweir 113cdf0e10cSrcweir}; 114cdf0e10cSrcweir 115cdf0e10cSrcweir}; }; }; }; 116cdf0e10cSrcweir 117cdf0e10cSrcweir#endif 118