Main Page   Class Hierarchy   Alphabetical List   Compound List   File List   Compound Members

/home/jeroen/FOX/fox/fox-1.7.33/include/FXComposeContext.h
00001 /********************************************************************************
00002 *                                                                               *
00003 *                         C o m p o s e - C o n t e x t                         *
00004 *                                                                               *
00005 *********************************************************************************
00006 * Copyright (C) 2005,2012 by Jeroen van der Zijp.   All Rights Reserved.        *
00007 *********************************************************************************
00008 * This library is free software; you can redistribute it and/or modify          *
00009 * it under the terms of the GNU Lesser General Public License as published by   *
00010 * the Free Software Foundation; either version 3 of the License, or             *
00011 * (at your option) any later version.                                           *
00012 *                                                                               *
00013 * This library is distributed in the hope that it will be useful,               *
00014 * but WITHOUT ANY WARRANTY; without even the implied warranty of                *
00015 * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the                 *
00016 * GNU Lesser General Public License for more details.                           *
00017 *                                                                               *
00018 * You should have received a copy of the GNU Lesser General Public License      *
00019 * along with this program.  If not, see <http://www.gnu.org/licenses/>          *
00020 ********************************************************************************/
00021 #ifndef FXCOMPOSECONTEXT_H
00022 #define FXCOMPOSECONTEXT_H
00023 
00024 #ifndef FXID_H
00025 #include "FXId.h"
00026 #endif
00027 
00028 namespace FX {
00029 
00030 
00031 class FXApp;
00032 class FXWindow;
00033 class FXFont;
00034 
00039 class FXAPI FXComposeContext : public FXId {
00040   FXDECLARE(FXComposeContext)
00041 protected:
00042   FXWindow  *window;            // Window we belong to
00043   FXSelector message;           // Message to send it
00044 private:
00045 #ifndef WIN32
00046   void* fontset;
00047   static int  editStartCallback(void*,FXComposeContext*,void*);
00048   static void editDoneCallback(void*,FXComposeContext*,void*);
00049   static void editDrawCallback(void*,FXComposeContext*,void*);
00050   static void editCaretCallback(void*,FXComposeContext*,void*);
00051   static void statusStartCallback(void*,FXComposeContext*,void*);
00052   static void statusDoneCallback(void*,FXComposeContext*,void*);
00053   static void statusDrawCallback(void*,FXComposeContext*,void*);
00054 #endif
00055 protected:
00056   FXComposeContext();
00057 private:
00058   FXComposeContext(const FXComposeContext&);
00059   FXComposeContext &operator=(const FXComposeContext&);
00060 public:
00061 
00063   FXComposeContext(FXApp* a,FXWindow* win=NULL,FXSelector sel=0);
00064 
00066   virtual void create();
00067 
00069   virtual void destroy();
00070 
00072   void focusIn();
00073 
00075   void focusOut();
00076 
00078   void setFont(FXFont* fnt);
00079 
00081   void setSpot(FXint x,FXint y);
00082 
00084   void setArea(FXint x,FXint y,FXint w,FXint h);
00085 
00087   FXString translateEvent(FXRawEvent& event);
00088 
00090   virtual ~FXComposeContext();
00091   };
00092 
00093 }
00094 
00095 #endif

Copyright © 1997-2011 Jeroen van der Zijp