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

/home/jeroen/FOX/fox/fox-1.7.33/include/FXImageFrame.h
00001 /********************************************************************************
00002 *                                                                               *
00003 *                       I m a g e   F r a m e   W i d g e t                     *
00004 *                                                                               *
00005 *********************************************************************************
00006 * Copyright (C) 2001,2012 by H. J. Daniel III. 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 FXIMAGEFRAME_H
00022 #define FXIMAGEFRAME_H
00023 
00024 #ifndef FXFRAME_H
00025 #include "FXFrame.h"
00026 #endif
00027 
00028 namespace FX {
00029 
00030 
00036 class FXAPI FXImageFrame : public FXFrame {
00037   FXDECLARE(FXImageFrame)
00038 protected:
00039   FXImage* image;       // The image being displayed
00040 protected:
00041   FXImageFrame();
00042 private:
00043   FXImageFrame(const FXImageFrame&);
00044   FXImageFrame &operator=(const FXImageFrame&);
00045 public:
00046   long onPaint(FXObject*,FXSelector,void* ptr);
00047 public:
00048 
00050   FXImageFrame(FXComposite* p,FXImage *img,FXuint opts=FRAME_SUNKEN|FRAME_THICK,FXint x=0,FXint y=0,FXint w=0,FXint h=0,FXint pl=0,FXint pr=0,FXint pt=0,FXint pb=0);
00051 
00053   virtual void create();
00054 
00056   virtual FXint getDefaultWidth();
00057 
00059   virtual FXint getDefaultHeight();
00060 
00062   void setImage(FXImage* img);
00063 
00065   FXImage* getImage() const { return image; }
00066 
00068   void setJustify(FXuint mode);
00069 
00071   FXuint getJustify() const;
00072 
00074   virtual void save(FXStream& store) const;
00075 
00077   virtual void load(FXStream& store);
00078 
00080   virtual ~FXImageFrame();
00081   };
00082 
00083 }
00084 
00085 
00086 #endif

Copyright © 1997-2011 Jeroen van der Zijp