render_frames.h
00001
00002
00003
00004
00005
00006
00007
00008
00009
00010
00011
00012
00013
00014
00015
00016
00017
00018
00019
00020
00021
00022
00023
00024 #ifndef __render_frames_h__
00025 #define __render_frames_h__
00026
00027 #include "rendering/render_replaced.h"
00028 #include "xml/dom_nodeimpl.h"
00029 #include "html/html_baseimpl.h"
00030 class KHTMLView;
00031
00032 namespace DOM
00033 {
00034 class HTMLFrameElementImpl;
00035 class HTMLElementImpl;
00036 class MouseEventImpl;
00037 }
00038
00039 namespace khtml
00040 {
00041 struct ChildFrame;
00042
00043 class RenderFrameSet : public RenderBox
00044 {
00045 friend class DOM::HTMLFrameSetElementImpl;
00046 public:
00047 RenderFrameSet( DOM::HTMLFrameSetElementImpl *frameSet );
00048
00049 virtual ~RenderFrameSet();
00050
00051 virtual const char *renderName() const { return "RenderFrameSet"; }
00052 virtual bool isFrameSet() const { return true; }
00053
00054 virtual void layout();
00055
00056 void positionFrames( );
00057
00058 bool resizing() const { return m_resizing; }
00059 bool noResize() const { return element()->noResize(); }
00060
00061 bool userResize( DOM::MouseEventImpl *evt );
00062 bool canResize( int _x, int _y);
00063 void setResizing(bool e);
00064
00065 Qt::CursorShape cursorShape() const { return m_cursor; }
00066
00067 bool nodeAtPoint(NodeInfo& info, int x, int y, int tx, int ty);
00068
00069 DOM::HTMLFrameSetElementImpl *element() const
00070 { return static_cast<DOM::HTMLFrameSetElementImpl*>(RenderObject::element()); }
00071
00072 #ifndef NDEBUG
00073 virtual void dump(QTextStream *stream, QString ind = "") const;
00074 #endif
00075
00076 private:
00077 Qt::CursorShape m_cursor;
00078 int m_oldpos;
00079 int m_gridLen[2];
00080 int* m_gridDelta[2];
00081 int* m_gridLayout[2];
00082
00083 bool *m_hSplitVar;
00084 bool *m_vSplitVar;
00085
00086 int m_hSplit;
00087 int m_vSplit;
00088 int m_hSplitPos;
00089 int m_vSplitPos;
00090
00091 bool m_resizing;
00092 bool m_clientresizing;
00093 };
00094
00095 class RenderPart : public khtml::RenderWidget
00096 {
00097 Q_OBJECT
00098 public:
00099 RenderPart(DOM::HTMLElementImpl* node);
00100
00101 virtual const char *renderName() const { return "RenderPart"; }
00102
00103 virtual void setWidget( QWidget *widget );
00104
00116 virtual bool partLoadingErrorNotify( khtml::ChildFrame *childFrame, const KURL& url, const QString& serviceType );
00117
00118 virtual short intrinsicWidth() const;
00119 virtual int intrinsicHeight() const;
00120
00121 public slots:
00122 virtual void slotViewCleared();
00123 };
00124
00125 class RenderFrame : public khtml::RenderPart
00126 {
00127 Q_OBJECT
00128 public:
00129 RenderFrame( DOM::HTMLFrameElementImpl *frame );
00130
00131 virtual const char *renderName() const { return "RenderFrame"; }
00132
00133 DOM::HTMLFrameElementImpl *element() const
00134 { return static_cast<DOM::HTMLFrameElementImpl*>(RenderObject::element()); }
00135
00136 public slots:
00137 void slotViewCleared();
00138 };
00139
00140
00141 class RenderPartObject : public khtml::RenderPart
00142 {
00143 Q_OBJECT
00144 public:
00145 RenderPartObject( DOM::HTMLElementImpl * );
00146
00147 virtual const char *renderName() const { return "RenderPartObject"; }
00148
00149 virtual void close();
00150
00151 virtual void layout( );
00152 virtual void updateWidget();
00153
00154 virtual bool partLoadingErrorNotify( khtml::ChildFrame *childFrame, const KURL& url, const QString& serviceType );
00155
00156 public slots:
00157 void slotViewCleared();
00158 private slots:
00159 void slotPartLoadingErrorNotify();
00160 };
00161
00162 }
00163
00164 #endif
This file is part of the documentation for kdelibs Version 3.1.4.