• Skip to content
  • Skip to link menu
Trinity API Reference
  • Trinity API Reference
  • tdeui
 

tdeui

  • tdeui
kpixmapio.h
1 /*
2  *
3  *
4  * This file is part of the KDE project, module tdeui.
5  * Copyright (C) 2000 Geert Jansen <jansen@kde.org>
6  *
7  * You can Freely distribute this program under the GNU Library General
8  * Public License. See the file "COPYING.LIB" for the exact licensing terms.
9  */
10 
11 #ifndef __KPixmapIO_h_Included__
12 #define __KPixmapIO_h_Included__
13 
14 #include <tdelibs_export.h>
15 
16 class TQPixmap;
17 class TQImage;
18 class TQPoint;
19 class TQRect;
20 struct KPixmapIOPrivate;
87 class TDEUI_EXPORT KPixmapIO
88 {
89 public:
90  KPixmapIO();
91  ~KPixmapIO();
92 
98  TQPixmap convertToPixmap(const TQImage &image);
99 
105  TQImage convertToImage(const TQPixmap &pixmap);
106 
114  void putImage(TQPixmap *dst, int dx, int dy, const TQImage *src);
115 
120  void putImage(TQPixmap *dst, const TQPoint &offset, const TQImage *src);
121 
131  TQImage getImage(const TQPixmap *src, int sx, int sy, int sw, int sh);
132 
137  TQImage getImage(const TQPixmap *src, const TQRect &rect);
138 
142  enum ShmPolicies {
143  ShmDontKeep,
144  ShmKeepAndGrow
145  };
146 
152  void setShmPolicy(int policy);
153 
159  void preAllocShm(int size);
160 
161 private:
162  /*
163  * Supported XImage byte orders. The notation ARGB means bytes
164  * containing A:R:G:B succeed in memory.
165  */
166  enum ByteOrders {
167  bo32_ARGB, bo32_BGRA, bo24_RGB, bo24_BGR,
168  bo16_RGB_565, bo16_BGR_565, bo16_RGB_555,
169  bo16_BGR_555, bo8
170  };
171 
172  bool m_bShm;
173  bool initXImage(int w, int h);
174  void doneXImage();
175  bool createXImage(int w, int h);
176  void destroyXImage();
177  bool createShmSegment(int size);
178  void destroyShmSegment();
179  void convertToXImage(const TQImage &);
180  TQImage convertFromXImage();
181 private:
182  KPixmapIOPrivate* d;
183 };
184 
185 #endif // __KPixmapIO_h_Included__
KPixmapIO::ShmPolicies
ShmPolicies
Shared memory allocation policies.
Definition: kpixmapio.h:142
KPixmapIO
Fast TQImage to/from TQPixmap conversion.
Definition: kpixmapio.h:87

tdeui

Skip menu "tdeui"
  • Main Page
  • Namespace List
  • Class Hierarchy
  • Alphabetical List
  • Class List
  • File List
  • Namespace Members
  • Class Members
  • Related Pages

tdeui

Skip menu "tdeui"
  • arts
  • dcop
  • dnssd
  • interfaces
  •   kspeech
  •     interface
  •     library
  •   tdetexteditor
  • kate
  • kded
  • kdoctools
  • kimgio
  • kjs
  • libtdemid
  • libtdescreensaver
  •     tdecore
  • tdeabc
  • tdecmshell
  • tdecore
  • tdefx
  • tdehtml
  • tdeinit
  • tdeio
  •   bookmarks
  •   httpfilter
  •   kpasswdserver
  •   kssl
  • tdeioslave
  •   http
  •   tdefile
  •   tdeio
  •   tdeioexec
  • tdemdi
  •   tdemdi
  • tdenewstuff
  • tdeparts
  • tdeprint
  • tderandr
  • tderesources
  • tdespell2
  • tdesu
  • tdeui
  • tdeunittest
  • tdeutils
  • tdewallet
Generated for tdeui by doxygen 1.8.8
This website is maintained by Timothy Pearson.