Panda3D
wordWrapStreamBuf.I
Go to the documentation of this file.
1 /**
2  * PANDA 3D SOFTWARE
3  * Copyright (c) Carnegie Mellon University. All rights reserved.
4  *
5  * All use of this software is subject to the terms of the revised BSD
6  * license. You should have received a copy of this license along
7  * with this source code in a file named "LICENSE."
8  *
9  * @file wordWrapStreamBuf.I
10  * @author drose
11  * @date 2000-07-01
12  */
13 
14 /**
15  * An internal function called to update the internal state according to the
16  * current value of the Notify::literal flag, which might or might not be set
17  * of the ostream at any time. When the literal flag is true, we should not
18  * word-wrap, so toggling this flag means we need to flush the current buffer.
19  */
20 INLINE void WordWrapStreamBuf::
21 set_literal_mode(bool mode) {
22  if (mode != _literal_mode) {
23  flush_data();
24  _literal_mode = mode;
25  }
26 }