kivio

KIvioStencilIface.h

00001 /* This file is part of the KDE project
00002    Copyright (C) 2001, Laurent MONTEL <lmontel@mandrakesoft.com>
00003 
00004    This library is free software; you can redistribute it and/or
00005    modify it under the terms of the GNU Library General Public
00006    License as published by the Free Software Foundation; either
00007    version 2 of the License, or (at your option) any later version.
00008 
00009    This library is distributed in the hope that it will be useful,
00010    but WITHOUT ANY WARRANTY; without even the implied warranty of
00011    MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the GNU
00012    Library General Public License for more details.
00013 
00014    You should have received a copy of the GNU Library General Public License
00015    along with this library; see the file COPYING.LIB.  If not, write to
00016    the Free Software Foundation, Inc., 51 Franklin Street, Fifth Floor,
00017    Boston, MA 02110-1301, USA.
00018 */
00019 
00020 #ifndef KIVIO_STENCIL_IFACE_H
00021 #define KIVIO_STENCIL_IFACE_H
00022 
00023 #include <dcopref.h>
00024 #include <dcopobject.h>
00025 #include <qstring.h>
00026 #include <qfont.h>
00027 #include <qcolor.h>
00028 #include <qrect.h>
00029 
00030 class KivioStencil;
00031 
00032 class KivioStencilIface : virtual public DCOPObject
00033 {
00034     K_DCOP
00035 public:
00036     KivioStencilIface(  KivioStencil *s );
00037 
00038 k_dcop:
00039     virtual DCOPRef ref();
00040     //virtual DCOPRef duplicate();
00041 
00042     virtual bool connected();
00043     virtual void setConnected(bool c);
00044 
00045     virtual double x();
00046     virtual void setX( double f );
00047 
00048     virtual double y();
00049     virtual void setY( double f );
00050 
00051     virtual double w();
00052     virtual void setW( double f );
00053 
00054     virtual double h();
00055     virtual void setH( double f );
00056 
00057     virtual QRect rect();
00058 
00059     virtual void setPosition( double f1, double f2 );
00060     virtual void setDimensions( double f1, double f2 );
00061 
00062     virtual QColor fgColor();
00063     virtual void setFGColor( QColor );
00064 
00065     virtual void setBGColor( QColor );
00066     virtual QColor bgColor();
00067 
00068     virtual void setLineWidth( double );
00069     virtual double lineWidth();
00070 
00071     // FOnt stuff
00072     virtual QColor textColor();
00073     virtual void setTextColor( QColor );
00074 
00075     virtual QFont textFont();
00076     virtual void setTextFont( const QFont & );
00077 
00078     virtual int hTextAlign();
00079     virtual int vTextAlign();
00080 
00081     virtual void setHTextAlign(int);
00082     virtual void setVTextAlign(int);
00083 
00084     virtual void setText( const QString & );
00085     virtual QString text();
00086 
00087     virtual bool isSelected();
00088     virtual void select();
00089     virtual void unselect();
00090     virtual void subSelect( const double &, const double & );
00091 
00092     //virtual KivioConnectorTarget *connectToTarget( KivioConnectorPoint *, int );
00093 
00094 private:
00095     KivioStencil *stencil;
00096 
00097 };
00098 
00099 #endif
KDE Home | KDE Accessibility Home | Description of Access Keys