00001 /************************************************************************* 00002 * 00003 * OpenOffice.org - a multi-platform office productivity suite 00004 * 00005 * $RCSfile: eqnolefilehdr.hxx,v $ 00006 * 00007 * $Revision: 1.3 $ 00008 * 00009 * last change: $Author: rt $ $Date: 2005/09/07 15:07:15 $ 00010 * 00011 * The Contents of this file are made available subject to 00012 * the terms of GNU Lesser General Public License Version 2.1. 00013 * 00014 * 00015 * GNU Lesser General Public License Version 2.1 00016 * ============================================= 00017 * Copyright 2005 by Sun Microsystems, Inc. 00018 * 901 San Antonio Road, Palo Alto, CA 94303, USA 00019 * 00020 * This library is free software; you can redistribute it and/or 00021 * modify it under the terms of the GNU Lesser General Public 00022 * License version 2.1, as published by the Free Software Foundation. 00023 * 00024 * This library is distributed in the hope that it will be useful, 00025 * but WITHOUT ANY WARRANTY; without even the implied warranty of 00026 * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU 00027 * Lesser General Public License for more details. 00028 * 00029 * You should have received a copy of the GNU Lesser General Public 00030 * License along with this library; if not, write to the Free Software 00031 * Foundation, Inc., 59 Temple Place, Suite 330, Boston, 00032 * MA 02111-1307 USA 00033 * 00034 ************************************************************************/ 00035 00036 #ifndef __EQNOLEFILEHDR_HXX__ 00037 #define __EQNOLEFILEHDR_HXX__ 00038 00039 #include <sal/types.h> 00040 00041 #ifndef _SOT_STORAGE_HXX 00042 #include <sot/storage.hxx> 00043 #endif 00044 00045 class SvStorageStream; 00046 class SotStorage; 00047 00048 #define EQNOLEFILEHDR_SIZE 28 00049 00050 class EQNOLEFILEHDR 00051 { 00052 public: 00053 EQNOLEFILEHDR() {} 00054 EQNOLEFILEHDR(sal_uInt32 nLenMTEF) : nCBHdr(0x1c),nVersion(0x20000), 00055 nCf(0xc1c6),nCBObject(nLenMTEF),nReserved1(0),nReserved2(0x0014F690), 00056 nReserved3(0x0014EBB4), nReserved4(0) {} 00057 00058 sal_uInt16 nCBHdr; // length of header, sizeof(EQNOLEFILEHDR) = 28 00059 sal_uInt32 nVersion; // hiword = 2, loword = 0 00060 sal_uInt16 nCf; // clipboard format ("MathType EF") 00061 sal_uInt32 nCBObject; // length of MTEF data following this header 00062 sal_uInt32 nReserved1; // not used 00063 sal_uInt32 nReserved2; // not used 00064 sal_uInt32 nReserved3; // not used 00065 sal_uInt32 nReserved4; // not used 00066 00067 void Read(SvStorageStream *pS); 00068 void Write(SvStorageStream *pS); 00069 }; 00070 00071 sal_Bool GetMathTypeVersion( SotStorage* pStor, sal_uInt8 &nVersion ); 00072 00073 #endif 00074