news download themes documentation links










WinClient Class Reference

Holds client window info. More...

#include <WinClient.hh>

Inheritance diagram for WinClient:

FbTk::FbWindow FbTk::FbDrawable List of all members.

Public Types

typedef std::list< WinClient * > TransientList
typedef WinClient::MwmHints MwmHints
enum  FocusMode { F_NOINPUT = 0, F_PASSIVE, F_LOCALLYACTIVE, F_GLOBALLYACTIVE }

Public Member Functions

 WinClient (Window win, BScreen &screen, FluxboxWindow *fbwin=0)
void updateRect (int x, int y, unsigned int width, unsigned int height)
bool sendFocus ()
void sendClose (bool forceful=false)
bool isClosable () const
void reparent (Window win, int x, int y)
void addModal ()
void removeModal ()
void updateWMClassHint ()
 updates from wm class hints

void updateWMProtocols ()
void updateTitle ()
void updateIconTitle ()
void updateTransientInfo ()
 updates transient window information

void updateBlackboxHints ()
void updateMWMHints ()
void updateWMHints ()
void updateWMNormalHints ()
void setStrut (Strut *strut)
void clearStrut ()
bool focus ()
void applySizeHints (int &width, int &height, int *display_width=0, int *display_height=0)
void setGroupLeftWindow (Window win)
void saveBlackboxAttribs (FluxboxWindow::BlackboxAttributes &blackbox_attribs)
bool validateClient () const
bool getAttrib (XWindowAttributes &attr) const
bool getWMName (XTextProperty &textprop) const
bool getWMIconName (XTextProperty &textprop) const
const std::string & getWMClassName () const
 name member of class structure

const std::string & getWMClassClass () const
 class member of class structure

BScreenscreen ()
const BScreenscreen () const
FbTk::Subject & dieSig ()
 notifies when this client dies

WinClienttransientFor ()
const WinClienttransientFor () const
TransientList & transientList ()
const TransientList & transientList () const
bool isTransient () const
bool isModal () const
bool operator== (const FluxboxWindow &win) const
const std::string & title () const
const std::string & iconTitle () const
const FluxboxWindowfbwindow () const
FluxboxWindowfbwindow ()
int gravity () const
bool hasGroupLeftWindow () const
Window getGroupLeftWindow () const
int getFocusMode () const
const FluxboxWindow::BlackboxHints * getBlackboxHint () const
const MwmHints * getMwmHint () const

Public Attributes

WinClienttransient_for
std::list< WinClient * > transients
Window window_group
int x
int y
int old_bw
unsigned int min_width
unsigned int min_height
unsigned int max_width
unsigned int max_height
unsigned int width_inc
unsigned int height_inc
unsigned int min_aspect_x
unsigned int min_aspect_y
unsigned int max_aspect_x
unsigned int max_aspect_y
unsigned int base_width
unsigned int base_height
unsigned long initial_state
unsigned long normal_hint_flags
unsigned long wm_hint_flags
FluxboxWindowm_win

Static Public Attributes

const int PropBlackboxHintsElements = 5
const int PropMwmHintsElements = 3

Detailed Description

Holds client window info.

Definition at line 38 of file WinClient.hh.


Member Function Documentation

void WinClient::applySizeHints int &  width,
int &  height,
int *  display_width = 0,
int *  display_height = 0
 

Changes width and height to the nearest (lower) value that conforms to it's size hints.

display_* give the values that would be displayed to the user when resizing. We use pointers for display_* since they are optional.

Definition at line 644 of file WinClient.cc.

00645                                                                         {
00646 
00647     int i = width, j = height;
00648 
00649     // Check minimum size
00650     if (width < 0 || width < static_cast<signed>(min_width)) 
00651         width = min_width;
00652 
00653     if (height < 0 || height < static_cast<signed>(min_height))
00654         height = min_height;
00655 
00656     // Check maximum size
00657     if (max_width > 0 && width > static_cast<signed>(max_width))
00658         width = max_width;
00659 
00660     if (max_height > 0 && height > static_cast<signed>(max_height))
00661         height = max_height;
00662 
00663     // enforce incremental size limits, wrt base size
00664     // only calculate this if we really need to
00665     i = (width - base_width) / width_inc;
00666     width = i*width_inc + base_width;
00667 
00668     j = (height - base_height) / height_inc;
00669     height = j*height_inc + base_height;
00670 
00671     if (display_width)
00672         *display_width = i;
00673 
00674     if (display_height)
00675         *display_height = j;
00676 }

void WinClient::updateRect int  x,
int  y,
unsigned int  width,
unsigned int  height
 

! TODO

! TODO

Definition at line 127 of file WinClient.cc.

References FbTk::App::instance(), and FbTk::FbWindow::window().

00128                                                                  {
00129     Display *disp = FbTk::App::instance()->display();
00130     XEvent event;
00131     event.type = ConfigureNotify;
00132 
00133     event.xconfigure.display = disp;
00134     event.xconfigure.event = window();
00135     event.xconfigure.window = window();
00136     event.xconfigure.x = x;
00137     event.xconfigure.y = y;
00138     event.xconfigure.width = width;
00139     event.xconfigure.height = height;
00141     event.xconfigure.border_width = 1;//client.old_bw;
00143     event.xconfigure.above = None; //m_frame.window().window();
00144     event.xconfigure.override_redirect = false;
00145 
00146     XSendEvent(disp, window(), False, StructureNotifyMask, &event);
00147 
00148 }


Member Data Documentation

WinClient* WinClient::transient_for
 

!! TODO !! remove or move these to private

Definition at line 156 of file WinClient.hh.

Referenced by updateTransientInfo().


The documentation for this class was generated from the following files:

Fluxbox CVS-Jan-2003




      



Got comments about the page? Send them to webmaster.
If you have general Fluxbox related questions ask them on our irc channel or mailing lists.

Show Source








Designed by aLEczapKA