Fct_Change_Mode

 

This function change the current window mode.

 

 

Syntax

 

void  Fct_Change_Mode(

          SliceO_Window *window,

          unsigned char mode

) ;

 

 

Parameters

 

window

Pointer to the window that will be affected.

 

mode

New window mode.  The new mode can be one of the following:

WINDOW_MODE_ALL

WINDOW_MODE_ONE

WINDOW_MODE_3D

 

 

Return value

 

This function does not return a value.

 

 

Remarks

 

 

Requirements

 

Header:

          sliceO_include.hpp

 

 

Library:

          sliceO_Structures.lib

 

 

Example

 

From window_Script.cpp

          ...

 

          char *t_window = pt_arg[0] ;

          cmd = pt_arg[1] ;

 

          SliceO_Window *list_pt[100] ;

          int list_nb = Fct_Match_Template_Window( t_window, 100, list_pt ) ;

 

          ...

 

          // ---------------------------------------------------

          if ( ! _strnicmp( cmd, "mode", 3 ) ) {

 

                    if ( ! Script_Arg_Check( "Window: id mode (one|all|3D)", nb_arg, 3 ) )

                              return( 0 ) ;

 

                    if ( ! _strnicmp( pt_arg[2], "one", 3 ) ) {

                              for ( int wind=0; wind < list_nb; wind++ )

                                          Fct_Change_Mode( list_pt[wind], WINDOW_MODE_ONE ) ;

                    }

                    if ( ! _strnicmp( pt_arg[2], "all", 3 ) ) {

                              for ( int wind=0; wind < list_nb; wind++ )

                                        Fct_Change_Mode( list_pt[wind], WINDOW_MODE_ALL ) ;

                    }

                    if ( ! _strnicmp( pt_arg[2], "3D", 2 ) ) {

                              for ( int wind=0; wind < list_nb; wind++ )

                                        Fct_Change_Mode( list_pt[wind], WINDOW_MODE_3D ) ;

                    }

                    return( 1 ) ;

          }

          ...

 

See also