Update ooo320-m1
[ooovba.git] / binfilter / inc / bf_sw / fmtinfmt.hxx
blob0d1e190996e881fdf3f98e065c266ec50699e7a4
1 /*************************************************************************
3 * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
4 *
5 * Copyright 2008 by Sun Microsystems, Inc.
7 * OpenOffice.org - a multi-platform office productivity suite
9 * $RCSfile: fmtinfmt.hxx,v $
10 * $Revision: 1.9 $
12 * This file is part of OpenOffice.org.
14 * OpenOffice.org is free software: you can redistribute it and/or modify
15 * it under the terms of the GNU Lesser General Public License version 3
16 * only, as published by the Free Software Foundation.
18 * OpenOffice.org is distributed in the hope that it will be useful,
19 * but WITHOUT ANY WARRANTY; without even the implied warranty of
20 * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
21 * GNU Lesser General Public License version 3 for more details
22 * (a copy is included in the LICENSE file that accompanied this code).
24 * You should have received a copy of the GNU Lesser General Public License
25 * version 3 along with OpenOffice.org. If not, see
26 * <http://www.openoffice.org/license.html>
27 * for a copy of the LGPLv3 License.
29 ************************************************************************/
30 #ifndef _FMTINFMT_HXX
31 #define _FMTINFMT_HXX
34 #ifndef _SFXPOOLITEM_HXX
35 #include <bf_svtools/poolitem.hxx>
36 #endif
37 class IntlWrapper;
38 namespace binfilter {
39 class SvxMacro;
40 class SvxMacroTableDtor;
42 class SwTxtINetFmt;
43 // ATT_INETFMT *********************************************
45 class SwFmtINetFmt: public SfxPoolItem
47 friend class SwTxtINetFmt;
49 String aURL; // die URL
50 String aTargetFrame; // in diesen Frame soll die URL
51 String aINetFmt;
52 String aVisitedFmt;
53 String aName; // Name des Links
54 SvxMacroTableDtor* pMacroTbl;
55 SwTxtINetFmt* pTxtAttr; // mein TextAttribut
56 USHORT nINetId;
57 USHORT nVisitedId;
58 public:
59 SwFmtINetFmt( const String& rURL, const String& rTarget );
60 SwFmtINetFmt( const SwFmtINetFmt& rAttr );
61 SwFmtINetFmt(); // for TypeInfo
62 virtual ~SwFmtINetFmt();
64 TYPEINFO();
66 // "pure virtual Methoden" vom SfxPoolItem
67 virtual int operator==( const SfxPoolItem& ) const;
68 virtual SfxPoolItem* Clone( SfxItemPool* pPool = 0 ) const;
69 virtual SfxPoolItem* Create(SvStream &, USHORT nVer) const;
70 virtual SvStream& Store(SvStream &, USHORT nIVer) const;
72 virtual BOOL QueryValue( ::com::sun::star::uno::Any& rVal,
73 BYTE nMemberId = 0 ) const;
74 virtual BOOL PutValue( const ::com::sun::star::uno::Any& rVal,
75 BYTE nMemberId = 0 );
77 virtual USHORT GetVersion( USHORT nFFVer ) const;
79 const SwTxtINetFmt* GetTxtINetFmt() const { return pTxtAttr; }
80 SwTxtINetFmt* GetTxtINetFmt() { return pTxtAttr; }
82 const String& GetValue() const { return aURL; }
83 void SetValue( const String& rS ) { aURL = rS; }
85 const String& GetName() const { return aName; }
86 void SetName( const String& rNm ) { aName = rNm; }
88 const String& GetTargetFrame() const { return aTargetFrame; }
89 void SetTargetFrame( const String& rNm ){ aTargetFrame = rNm; }
91 const String& GetINetFmt() const { return aINetFmt; }
92 void SetINetFmt( const String& rNm ) { aINetFmt = rNm; }
94 const String& GetVisitedFmt() const { return aVisitedFmt; }
95 void SetVisitedFmt( const String& rNm ) { aVisitedFmt = rNm; }
97 USHORT GetINetFmtId() const { return nINetId; }
98 void SetINetFmtId( USHORT nNew ) { nINetId = nNew; }
100 USHORT GetVisitedFmtId() const { return nVisitedId; }
101 void SetVisitedFmtId( USHORT nNew ) { nVisitedId = nNew; }
103 // setze eine neue oder loesche die akt. MakroTabelle
104 const SvxMacroTableDtor* GetMacroTbl() const { return pMacroTbl; }
106 // setze / erfrage ein Makro
107 /*N #i27164#*/ void SetMacro( USHORT nEvent, const SvxMacro& rMacro );
108 const SvxMacro* GetMacro( USHORT nEvent ) const;
112 } //namespace binfilter
113 #endif