Back to index

texmacs  1.0.7.15
tm_data.hpp
Go to the documentation of this file.
00001 
00002 /******************************************************************************
00003 * MODULE     : tm_data.hpp
00004 * DESCRIPTION: Buffer management for TeXmacs server
00005 * COPYRIGHT  : (C) 1999  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 #ifndef TM_DATA_H
00013 #define TM_DATA_H
00014 #include "server.hpp"
00015 #include "tm_window.hpp"
00016 
00017 extern array<tm_buffer> bufs;
00018 
00019 /* Commodity macros */
00020 inline tm_buffer get_buffer () {
00021   return get_server () -> get_buffer (); }
00022 inline tm_view get_view (bool must_be_valid= true) {
00023   return get_server () -> get_view (must_be_valid); }
00024 inline tm_window get_window () {
00025   return get_server () -> get_window (); }
00026 inline void set_view (tm_view vw) {
00027   get_server () -> set_view (vw); }
00028 inline void set_message (tree left, tree right, bool temp= false) {
00029   get_server () -> set_message (left, right, temp); }
00030 
00031 #endif // defined TM_DATA_H