Back to index

texmacs  1.0.7.15
drd_mode.cpp
Go to the documentation of this file.
00001 
00002 /******************************************************************************
00003 * MODULE     : drd_mode.cpp
00004 * DESCRIPTION: data relation descriptions
00005 * COPYRIGHT  : (C) 2003  Joris van der Hoeven
00006 *******************************************************************************
00007 * This software falls under the GNU general public license version 3 or later.
00008 * It comes WITHOUT ANY WARRANTY WHATSOEVER. For details, see the file LICENSE
00009 * in the root directory or <http://www.gnu.org/licenses/gpl-3.0.html>.
00010 ******************************************************************************/
00011 
00012 #include "drd_mode.hpp"
00013 
00014 static int drd_access_mode  = DRD_ACCESS_NORMAL;
00015 static int drd_writable_mode= DRD_WRITABLE_NORMAL;
00016 
00017 int
00018 set_access_mode (int mode) {
00019   int old_mode= drd_access_mode;
00020   drd_access_mode= mode;
00021   return old_mode;
00022 }
00023 
00024 int
00025 get_access_mode () {
00026   return drd_access_mode;
00027 }
00028 
00029 int
00030 set_writable_mode (int mode) {
00031   int old_mode= drd_writable_mode;
00032   drd_writable_mode= mode;
00033   return old_mode;
00034 }
00035 
00036 int
00037 get_writable_mode () {
00038   return drd_writable_mode;
00039 }