Add NEWS bug entry for previous FvwmForm commit.
[fvwm.git] / fvwm / session.h
blob2b97230ccdcb68f451e2b52e594908eb3f5d57c2
1 /* -*-c-*- */
3 /* Description:
4 * exports from session.c shall go into this file
6 * Created:
7 * 4 April 1999 - Steve Robbins <steve@nyongwa.montreal.qc.ca>
8 */
10 #ifndef SESSION_H
11 #define SESSION_H
15 ** Load and save the 'global', ie not window-related, state of fvwm
16 ** into a file.
18 void LoadGlobalState(char *filename);
21 ** Turn off SM for new windows
23 void DisableRestoringState(void);
26 ** Load and save window states.
28 void LoadWindowStates (char *filename);
31 ** Save state to the named file, and if running under SM,
32 ** make the SM properly restart fvwm.
34 void RestartInSession (char *filename, Bool isNative, Bool doPreserveState);
37 ** Fill in the FvwmWindow struct with information saved from
38 ** the last session. This expects the fields
39 ** t->w
40 ** t->name
41 ** t->class
42 ** t->tmpflags.NameChanged
43 ** to have meaningful values. The shade and maximize flags are set
44 ** if the window should start out as shaded or maximized, respecively.
45 ** The dimensions returned in x, y, w, h should be used when the
46 ** window is to be maximized.
48 typedef struct
50 int shade_dir;
51 unsigned do_shade : 1;
52 unsigned used_title_dir_for_shading : 1;
53 unsigned do_max : 1;
54 } mwtsm_state_args;
56 Bool MatchWinToSM(
57 FvwmWindow *ewin, mwtsm_state_args *ret_state_args,
58 initial_window_options_t *win_opts);
60 void SetClientID(char *client_id);
63 ** Try to open a connection to the session manager. If non-NULL,
64 ** reuse the client_id.
66 void SessionInit(void);
69 ** The file number of the session manager connection or -1
70 ** if no session manager was found.
72 extern int sm_fd;
75 ** Process messages received from the session manager. Call this
76 ** from the main event loop when there is input waiting sm_fd.
78 void ProcessICEMsgs(void);
81 * Fvwm Function implementation
83 Bool quitSession(void);
84 Bool saveSession(void);
85 Bool saveQuitSession(void);
87 #endif