LCOV - code coverage report
Current view: top level - starmath/inc - types.hxx (source / functions) Hit Total Coverage
Test: commit 10e77ab3ff6f4314137acd6e2702a6e5c1ce1fae Lines: 1 1 100.0 %
Date: 2014-11-03 Functions: 1 1 100.0 %
Legend: Lines: hit not hit

          Line data    Source code
       1             : /* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
       2             : /*
       3             :  * This file is part of the LibreOffice project.
       4             :  *
       5             :  * This Source Code Form is subject to the terms of the Mozilla Public
       6             :  * License, v. 2.0. If a copy of the MPL was not distributed with this
       7             :  * file, You can obtain one at http://mozilla.org/MPL/2.0/.
       8             :  *
       9             :  * This file incorporates work covered by the following license notice:
      10             :  *
      11             :  *   Licensed to the Apache Software Foundation (ASF) under one or more
      12             :  *   contributor license agreements. See the NOTICE file distributed
      13             :  *   with this work for additional information regarding copyright
      14             :  *   ownership. The ASF licenses this file to you under the Apache
      15             :  *   License, Version 2.0 (the "License"); you may not use this file
      16             :  *   except in compliance with the License. You may obtain a copy of
      17             :  *   the License at http://www.apache.org/licenses/LICENSE-2.0 .
      18             :  */
      19             : 
      20             : #ifndef INCLUDED_STARMATH_INC_TYPES_HXX
      21             : #define INCLUDED_STARMATH_INC_TYPES_HXX
      22             : 
      23             : #include <sal/types.h>
      24             : #define FONTNAME_MATH   "OpenSymbol"
      25             : 
      26             : 
      27             : 
      28             : enum SmPrintSize { PRINT_SIZE_NORMAL, PRINT_SIZE_SCALED, PRINT_SIZE_ZOOMED };
      29             : 
      30             : 
      31             : 
      32        5544 : inline bool IsInPrivateUseArea( sal_Unicode cChar ) { return 0xE000 <= cChar  &&  cChar <= 0xF8FF; }
      33             : 
      34             : // Greek char range as seen in svx/.../charmap.cxx RID_SUBSETSTR_BASIC_GREEK
      35             : inline bool IsGreekChar( sal_Unicode cChar ) { return 0x0370 <= cChar  &&  cChar <= 0x03FF; }
      36             : 
      37             : sal_Unicode ConvertMathToMathML( sal_Unicode cChar );
      38             : 
      39             : 
      40             : // enum definitions for characters from the 'StarSymbol' font
      41             : // (some chars have more than one alias!)
      42             : //! Note: not listed here does not(!) mean "not used"
      43             : //!     (see %alpha ... %gamma for example)
      44             : 
      45             : enum MathSymbol
      46             : {
      47             :     MS_FACT         = (sal_Unicode) 0x0021,
      48             :     MS_INFINITY     = (sal_Unicode) 0x221E,
      49             :     MS_SLASH        = (sal_Unicode) 0x002F,
      50             : 
      51             :     MS_NDIVIDES     = (sal_Unicode) 0x2224,
      52             :     MS_DRARROW      = (sal_Unicode) 0x21D2,
      53             :     MS_DLARROW      = (sal_Unicode) 0x21D0,
      54             :     MS_DLRARROW     = (sal_Unicode) 0x21D4,
      55             :     MS_OVERBRACE    = (sal_Unicode) 0x23DE,
      56             :     MS_UNDERBRACE   = (sal_Unicode) 0x23DF,
      57             :     MS_CIRC         = (sal_Unicode) 0x2218,
      58             :     MS_ASSIGN       = (sal_Unicode) 0x003D,
      59             :     MS_ERROR        = (sal_Unicode) 0x00BF,
      60             : 
      61             :     MS_NEQ          = (sal_Unicode) 0x2260,
      62             :     MS_PLUS         = (sal_Unicode) 0x002B,
      63             :     MS_MINUS        = (sal_Unicode) 0x2212,
      64             :     MS_MULTIPLY     = (sal_Unicode) 0x2217,
      65             :     MS_TIMES        = (sal_Unicode) 0x00D7,
      66             :     MS_CDOT         = (sal_Unicode) 0x22C5,
      67             :     MS_DIV          = (sal_Unicode) 0x00F7,
      68             :     MS_PLUSMINUS    = (sal_Unicode) 0x00B1,
      69             :     MS_MINUSPLUS    = (sal_Unicode) 0x2213,
      70             :     MS_OPLUS        = (sal_Unicode) 0x2295,
      71             :     MS_OMINUS       = (sal_Unicode) 0x2296,
      72             :     MS_OTIMES       = (sal_Unicode) 0x2297,
      73             :     MS_ODIVIDE      = (sal_Unicode) 0x2298,
      74             :     MS_ODOT         = (sal_Unicode) 0x2299,
      75             :     MS_UNION        = (sal_Unicode) 0x222A,
      76             :     MS_INTERSECT    = (sal_Unicode) 0x2229,
      77             : 
      78             :     MS_LT           = (sal_Unicode) 0x003C,
      79             :     MS_GT           = (sal_Unicode) 0x003E,
      80             :     MS_LE           = (sal_Unicode) 0x2264,
      81             :     MS_GE           = (sal_Unicode) 0x2265,
      82             :     MS_LESLANT      = (sal_Unicode) 0x2A7D,
      83             :     MS_GESLANT      = (sal_Unicode) 0x2A7E,
      84             :     MS_LL           = (sal_Unicode) 0x226A,
      85             :     MS_GG           = (sal_Unicode) 0x226B,
      86             :     MS_SIM          = (sal_Unicode) 0x223C,
      87             :     MS_SIMEQ        = (sal_Unicode) 0x2243,
      88             :     MS_APPROX       = (sal_Unicode) 0x2248,
      89             :     MS_DEF          = (sal_Unicode) 0x225D,
      90             :     MS_EQUIV        = (sal_Unicode) 0x2261,
      91             :     MS_PROP         = (sal_Unicode) 0x221D,
      92             :     MS_PARTIAL      = (sal_Unicode) 0x2202,
      93             : 
      94             :     MS_SUBSET       = (sal_Unicode) 0x2282,
      95             :     MS_SUPSET       = (sal_Unicode) 0x2283,
      96             :     MS_SUBSETEQ     = (sal_Unicode) 0x2286,
      97             :     MS_SUPSETEQ     = (sal_Unicode) 0x2287,
      98             :     MS_NSUBSET      = (sal_Unicode) 0x2284,
      99             :     MS_NSUPSET      = (sal_Unicode) 0x2285,
     100             :     MS_NSUBSETEQ    = (sal_Unicode) 0x2288,
     101             :     MS_NSUPSETEQ    = (sal_Unicode) 0x2289,
     102             :     MS_IN           = (sal_Unicode) 0x2208,
     103             :     MS_NOTIN        = (sal_Unicode) 0x2209,
     104             :     MS_EXISTS       = (sal_Unicode) 0x2203,
     105             :     MS_NOTEXISTS    = (sal_Unicode) 0x2204,
     106             :     MS_BACKEPSILON  = (sal_Unicode) 0x220D,
     107             :     MS_ALEPH        = (sal_Unicode) 0x2135,
     108             :     MS_IM           = (sal_Unicode) 0x2111,
     109             :     MS_RE           = (sal_Unicode) 0x211C,
     110             :     MS_WP           = (sal_Unicode) 0x2118,
     111             : 
     112             :     MS_LINE         = (sal_Unicode) 0x2223,
     113             :     MS_VERTLINE     = (sal_Unicode) 0x007C,
     114             :     MS_DLINE        = (sal_Unicode) 0x2225,
     115             :     MS_DVERTLINE    = (sal_Unicode) 0x2016,
     116             :     MS_ORTHO        = (sal_Unicode) 0x22A5,
     117             :     MS_DOTSLOW      = (sal_Unicode) 0x2026,
     118             :     MS_DOTSAXIS     = (sal_Unicode) 0x22EF,
     119             :     MS_DOTSVERT     = (sal_Unicode) 0x22EE,
     120             :     MS_DOTSUP       = (sal_Unicode) 0x22F0,
     121             :     MS_DOTSDOWN     = (sal_Unicode) 0x22F1,
     122             :     MS_TRANSR       = (sal_Unicode) 0x22B6,
     123             :     MS_TRANSL       = (sal_Unicode) 0x22B7,
     124             :     MS_BACKSLASH    = (sal_Unicode) 0x2216,
     125             :     MS_NEG          = (sal_Unicode) 0x00AC,
     126             : 
     127             :     MS_FORALL       = (sal_Unicode) 0x2200,
     128             :     MS_NABLA        = (sal_Unicode) 0x2207,
     129             :     MS_PROD         = (sal_Unicode) 0x220F,
     130             :     MS_COPROD       = (sal_Unicode) 0x2210,
     131             :     MS_SUM          = (sal_Unicode) 0x2211,
     132             :     MS_SQRT         = (sal_Unicode) 0x221A,
     133             :     MS_INT          = (sal_Unicode) 0x222B,
     134             :     MS_IINT         = (sal_Unicode) 0x222C,
     135             :     MS_IIINT        = (sal_Unicode) 0x222D,
     136             :     MS_LINT         = (sal_Unicode) 0x222E,
     137             :     MS_LLINT        = (sal_Unicode) 0x222F,
     138             :     MS_LLLINT       = (sal_Unicode) 0x2230,
     139             : 
     140             :     MS_GRAVE        = (sal_Unicode) 0x0060,
     141             :     MS_COMBGRAVE    = (sal_Unicode) 0x0300,
     142             :     MS_ACUTE        = (sal_Unicode) 0x00B4,
     143             :     MS_COMBACUTE    = (sal_Unicode) 0x0301,
     144             :     MS_HAT          = (sal_Unicode) 0x005E,
     145             :     MS_COMBHAT      = (sal_Unicode) 0x0302,
     146             :     MS_TILDE        = (sal_Unicode) 0x007E,
     147             :     MS_COMBTILDE    = (sal_Unicode) 0x0303,
     148             :     MS_BAR          = (sal_Unicode) 0x00AF,
     149             :     MS_COMBBAR      = (sal_Unicode) 0x0304,
     150             :     MS_BREVE        = (sal_Unicode) 0x02D8,
     151             :     MS_COMBBREVE    = (sal_Unicode) 0x0306,
     152             :     MS_CIRCLE       = (sal_Unicode) 0x02DA,
     153             :     MS_COMBCIRCLE   = (sal_Unicode) 0x030A,
     154             :     MS_CHECK        = (sal_Unicode) 0x02C7,
     155             :     MS_COMBCHECK    = (sal_Unicode) 0x030C,
     156             :     MS_VEC          = (sal_Unicode) 0x20D7,
     157             :     MS_DOT          = (sal_Unicode) 0x02D9,
     158             :     MS_DDOT         = (sal_Unicode) 0x00A8,
     159             :     MS_DDDOT        = (sal_Unicode) 0x20DB,
     160             :     MS_AND          = (sal_Unicode) 0x2227,
     161             :     MS_OR           = (sal_Unicode) 0x2228,
     162             :     MS_NI           = (sal_Unicode) 0x220B,
     163             :     MS_EMPTYSET     = (sal_Unicode) 0x2205,
     164             : 
     165             :     MS_LPARENT      = (sal_Unicode) 0x0028,
     166             :     MS_RPARENT      = (sal_Unicode) 0x0029,
     167             :     MS_LBRACKET     = (sal_Unicode) 0x005B,
     168             :     MS_RBRACKET     = (sal_Unicode) 0x005D,
     169             :     MS_LBRACE       = (sal_Unicode) 0x007B,
     170             :     MS_RBRACE       = (sal_Unicode) 0x007D,
     171             :     MS_LCEIL        = (sal_Unicode) 0x2308,
     172             :     MS_RCEIL        = (sal_Unicode) 0x2309,
     173             :     MS_LFLOOR       = (sal_Unicode) 0x230A,
     174             :     MS_RFLOOR       = (sal_Unicode) 0x230B,
     175             :     MS_LANGLE       = (sal_Unicode) 0x2329,
     176             :     MS_RANGLE       = (sal_Unicode) 0x232A,
     177             :     MS_LDBRACKET    = (sal_Unicode) 0x27E6,
     178             :     MS_RDBRACKET    = (sal_Unicode) 0x27E7,
     179             :     MS_LMATHANGLE   = (sal_Unicode) 0x27E8,
     180             :     MS_RMATHANGLE   = (sal_Unicode) 0x27E9,
     181             : 
     182             :     MS_PLACE        = (sal_Unicode) 0x2751,
     183             : 
     184             :     MS_LAMBDABAR    = (sal_Unicode) 0x019B,
     185             :     MS_HBAR         = (sal_Unicode) 0x210F,
     186             :     MS_LEFTARROW    = (sal_Unicode) 0x2190,
     187             :     MS_UPARROW      = (sal_Unicode) 0x2191,
     188             :     MS_RIGHTARROW   = (sal_Unicode) 0x2192,
     189             :     MS_DOWNARROW    = (sal_Unicode) 0x2193,
     190             :     MS_SETN         = (sal_Unicode) 0x2115,
     191             :     MS_SETZ         = (sal_Unicode) 0x2124,
     192             :     MS_SETQ         = (sal_Unicode) 0x211A,
     193             :     MS_SETR         = (sal_Unicode) 0x211D,
     194             :     MS_SETC         = (sal_Unicode) 0x2102,
     195             : 
     196             :     MS_PERCENT      = (sal_Unicode) 0x0025,
     197             : 
     198             :     MS_PRECEDES     = (sal_Unicode) 0x227A,
     199             :     MS_PRECEDESEQUAL= (sal_Unicode) 0x227C,
     200             :     MS_PRECEDESEQUIV= (sal_Unicode) 0x227E,
     201             :     MS_SUCCEEDS     = (sal_Unicode) 0x227B,
     202             :     MS_SUCCEEDSEQUAL= (sal_Unicode) 0x227D,
     203             :     MS_SUCCEEDSEQUIV= (sal_Unicode) 0x227F,
     204             :     MS_NOTPRECEDES  = (sal_Unicode) 0x2280,
     205             :     MS_NOTSUCCEEDS  = (sal_Unicode) 0x2281,
     206             : };
     207             : 
     208             : #endif
     209             : 
     210             : /* vim:set shiftwidth=4 softtabstop=4 expandtab: */

Generated by: LCOV version 1.10