Main Page   Class Hierarchy   Compound List   File List   Header Files   Compound Members   File Members  

KWnd Class Reference

The base class for all native widgets. More...

#include <cmnwnd.hpp>

Class diagram for KWnd:

KWindow KWidget KScroll KList KLabel KEdit KChoice KButton

List of all members.


Public Members

 KWnd ()
virtual bool OnPosChanged ( int x, int y, int width, int height)
virtual bool OnPaint ( int x, int y, int width, int height)
virtual bool OnEraseBkgnd ( BView * view)
virtual bool OnOwnerDraw ( )
virtual bool OnMouseDown ( int btn, int x, int y)
virtual bool OnMouseUp ( int btn, int x, int y)
virtual bool OnMouseMove ( int x, int y)
virtual bool OnMouseEnter ( int x, int y)
virtual bool OnMouseExit ( int x, int y)
virtual bool OnContextMenu ( int x, int y)
virtual bool OnFocusChange ( bool gain)
virtual bool OnActivate ( int flags, bool min, BWindow * handle)
virtual bool OnClose ()
virtual bool OnCommand ( int cmd)
virtual bool OnScroll ( int pos, int op, bool vert)
virtual bool OnSetCursor ()
virtual bool OnChar ( char c, int data)
virtual bool OnKeyDown ( int virtKey, int keyData)
virtual bool OnKeyUp ( int virtKey, int keyData)
virtual HBRUSH OnCtlColor ( BView * view)
virtual bool updateInsets ()
virtual int convertKey ( int virtKey, int* scan, int* chr)
virtual int getKeyMods ()
virtual char* getText ()
There is no generic BView method to get the object text, ONLY SUBCLASSES OF KWnd IMPLEMENT THIS.

virtual void setText (jstring text)
There is no generic BView method to set the object text, ONLY SUBCLASSES OF KWnd IMPLEMENT THIS.

virtual void setVisible (jboolean b)
virtual void setFocus ()
virtual void setEnabled (jboolean b)
ONLY SUBCLASSES OF KWnd IMPLEMENT THIS.

virtual void setBounds (int x, int y, int width, int height)
virtual void setForeground (rgb_color c)
virtual void setBackground (rgb_color c)
virtual void setFont (BFont * f)
virtual void setCursor (BCursor * cursor)
virtual void invalidate ()
virtual jobject getPreferredSize ()
virtual void postEvent (BMessage * msg)
virtual bool processMenuAction ( int idx)
void setView (BView * view)
BViewgetView ()
BWindow* getWindow ()
bool lock ()
Locks the native component's looper. More...

void unlock ()
int srcIdx
BRect insets
rgb_color fg
rgb_color bg
BFont* fnt
BCursor* cursor

Detailed Description

The base class for all native widgets.

Every widget maps to one or more BView objects and receives events through the OnXXXX methods. For more details on the event system, see evt.cpp.

See widget.cpp for the simplest example of a descendant.


Member Function Documentation

KWnd::KWnd () [inline]

bool KWnd::OnPosChanged (int x, int y, int width, int height) [virtual]

Reimplemented in KWindow.

bool KWnd::OnPaint (int x, int y, int width, int height) [virtual]

Reimplemented in KWidget, and KWindow.

bool KWnd::OnEraseBkgnd (BView * view) [virtual]

bool KWnd::OnOwnerDraw () [virtual]

bool KWnd::OnMouseDown (int btn, int x, int y) [virtual]

bool KWnd::OnMouseUp (int btn, int x, int y) [virtual]

Reimplemented in KButton.

bool KWnd::OnMouseMove (int x, int y) [virtual]

bool KWnd::OnMouseEnter (int x, int y) [virtual]

bool KWnd::OnMouseExit (int x, int y) [virtual]

bool KWnd::OnContextMenu (int x, int y) [virtual]

bool KWnd::OnFocusChange (bool gain) [virtual]

Reimplemented in KButton.

bool KWnd::OnActivate (int flags, bool min, BWindow * handle) [virtual]

Reimplemented in KWindow.

bool KWnd::OnClose () [virtual]

Reimplemented in KWindow.

bool KWnd::OnCommand (int cmd) [virtual]

Reimplemented in KButton, KChoice, KList, and KWindow.

bool KWnd::OnScroll (int trackPos, int op, bool vert) [virtual]

Reimplemented in KScroll.

bool KWnd::OnSetCursor () [virtual]

Reimplemented in KWindow.

virtual bool KWnd::OnChar (char c, int data) [virtual]

bool KWnd::OnKeyDown (int virtKey, int data) [virtual]

Reimplemented in KEdit.

bool KWnd::OnKeyUp (int virtKey, int data) [virtual]

HBRUSH KWnd::OnCtlColor (BView * view) [virtual]

bool KWnd::updateInsets () [virtual]

Reimplemented in KWindow.

int KWnd::convertKey (int virtKey, int * scan, int * chr) [virtual]

int KWnd::getKeyMods () [virtual]

char * KWnd::getText () [virtual]

There is no generic BView method to get the object text, ONLY SUBCLASSES OF KWnd IMPLEMENT THIS.

Reimplemented in KEdit, and KLabel.

void KWnd::setText (jstring text) [virtual]

There is no generic BView method to set the object text, ONLY SUBCLASSES OF KWnd IMPLEMENT THIS.

Reimplemented in KButton, KEdit, and KLabel.

void KWnd::setVisible (jboolean b) [virtual]

Reimplemented in KWindow.

void KWnd::setFocus () [virtual]

void KWnd::setEnabled (jboolean en) [virtual]

ONLY SUBCLASSES OF KWnd IMPLEMENT THIS.

Reimplemented in KButton.

void KWnd::setBounds (int x, int y, int w, int h) [virtual]

Reimplemented in KChoice, and KWindow.

void KWnd::setForeground (rgb_color c) [virtual]

Reimplemented in KEdit.

void KWnd::setBackground (rgb_color c) [virtual]

void KWnd::setFont (BFont * f) [virtual]

Reimplemented in KEdit.

void KWnd::setCursor (BCursor * cursor) [virtual]

void KWnd::invalidate () [virtual]

jobject KWnd::getPreferredSize () [virtual]

Reimplemented in KChoice.

void KWnd::postEvent (BMessage * msg) [virtual]

bool KWnd::processMenuAction (int id) [virtual]

void KWnd::setView (BView * view) [inline]

BView * KWnd::getView () [inline]

BWindow * KWnd::getWindow () [inline]

bool KWnd::lock ()

Locks the native component's looper.

Sports a timeout of 5 secs and some debugging aids

void KWnd::unlock ()


Member Data Documentation

int KWnd::srcIdx

BRect KWnd::insets

rgb_color KWnd::fg

rgb_color KWnd::bg

BFont* KWnd::fnt

BCursor* KWnd::cursor


The documentation for this class was generated from the following files:
Generated at Sat Jun 10 12:37:10 2000 by doxygen 1.0.0 written by Dimitri van Heesch, © 1997-1999