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

FXSplashWindow.h
1 /********************************************************************************
2 * *
3 * S p l a s h W i n d o w *
4 * *
5 *********************************************************************************
6 * Copyright (C) 2004,2024 by Jeroen van der Zijp. All Rights Reserved. *
7 *********************************************************************************
8 * This library is free software; you can redistribute it and/or modify *
9 * it under the terms of the GNU Lesser General Public License as published by *
10 * the Free Software Foundation; either version 3 of the License, or *
11 * (at your option) any later version. *
12 * *
13 * This library is distributed in the hope that it will be useful, *
14 * but WITHOUT ANY WARRANTY; without even the implied warranty of *
15 * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the *
16 * GNU Lesser General Public License for more details. *
17 * *
18 * You should have received a copy of the GNU Lesser General Public License *
19 * along with this program. If not, see <http://www.gnu.org/licenses/> *
20 ********************************************************************************/
21 #ifndef FXSPLASHWINDOW_H
22 #define FXSPLASHWINDOW_H
23 
24 #ifndef FXTOPWINDOW_H
25 #include "FXTopWindow.h"
26 #endif
27 
28 namespace FX {
29 
30 
32 enum {
33  SPLASH_SIMPLE = 0,
34  SPLASH_SHAPED = 0x02000000,
35  SPLASH_OWNS_ICON = 0x04000000,
36  SPLASH_DESTROY = 0x08000000
37  };
38 
39 
46 class FXAPI FXSplashWindow : public FXTopWindow {
47  FXDECLARE(FXSplashWindow)
48 protected:
49  FXIcon *icon; // Really big icon
50  FXTime delay; // Delay before hiding
51 protected:
53 private:
55  FXSplashWindow &operator=(const FXSplashWindow&);
56 public:
57  long onPaint(FXObject*,FXSelector,void*);
58 public:
59 
66  FXSplashWindow(FXApp* ap,FXIcon* ic,FXuint opts=SPLASH_SIMPLE,FXTime ns=2000000000);
67 
74  FXSplashWindow(FXWindow* ow,FXIcon* ic,FXuint opts=SPLASH_SIMPLE,FXTime ns=2000000000);
75 
77  virtual void create();
78 
80  virtual void detach();
81 
83  virtual void show();
84 
86  virtual void show(FXuint placement);
87 
89  virtual void hide();
90 
92  virtual FXint getDefaultWidth();
93 
95  virtual FXint getDefaultHeight();
96 
98  void setIcon(FXIcon* ic);
99 
101  FXIcon* getIcon() const { return icon; }
102 
104  void setDelay(FXTime ns);
105 
107  FXTime getDelay() const { return delay; }
108 
110  virtual void save(FXStream& store) const;
111 
113  virtual void load(FXStream& store);
114 
116  virtual ~FXSplashWindow();
117  };
118 
119 }
120 
121 #endif
Window is the base class for all widgets in FOX.
Definition: FXWindow.h:130
The Application object is the central point of a FOX user-interface.
Definition: FXApp.h:134
A stream is a way to serialize data and objects into a byte stream.
Definition: FXStream.h:81
FXIcon * getIcon() const
Get the icon for this splash window.
Definition: FXSplashWindow.h:101
Definition: FX4Splitter.h:28
An Icon is an image with two additional server-side resources: a shape bitmap, which is used to mask ...
Definition: FXIcon.h:42
Abstract base class for all top-level windows.
Definition: FXTopWindow.h:97
Object is the base class for all objects in FOX; in order to receive messages from the user interface...
Definition: FXObject.h:134
The Splash Window is a window typically shown during startup of an application.
Definition: FXSplashWindow.h:46
FXTime getDelay() const
Return delay.
Definition: FXSplashWindow.h:107

Copyright © 1997-2022 Jeroen van der Zijp