00001 // Filename: eggComment.cxx 00002 // Created by: drose (20Jan99) 00003 // 00004 //////////////////////////////////////////////////////////////////// 00005 // 00006 // PANDA 3D SOFTWARE 00007 // Copyright (c) 2001, Disney Enterprises, Inc. All rights reserved 00008 // 00009 // All use of this software is subject to the terms of the Panda 3d 00010 // Software license. You should have received a copy of this license 00011 // along with this source code; you will also find a current copy of 00012 // the license at http://www.panda3d.org/license.txt . 00013 // 00014 // To contact the maintainers of this program write to 00015 // panda3d@yahoogroups.com . 00016 // 00017 //////////////////////////////////////////////////////////////////// 00018 00019 #include "eggComment.h" 00020 #include "eggMiscFuncs.h" 00021 00022 #include <indent.h> 00023 #include <string_utils.h> 00024 00025 TypeHandle EggComment::_type_handle; 00026 00027 00028 //////////////////////////////////////////////////////////////////// 00029 // Function: EggComment::write 00030 // Access: Public, Virtual 00031 // Description: Writes the comment definition to the indicated output 00032 // stream in Egg format. 00033 //////////////////////////////////////////////////////////////////// 00034 void EggComment:: 00035 write(ostream &out, int indent_level) const { 00036 write_header(out, indent_level, "<Comment>"); 00037 enquote_string(out, get_comment(), indent_level + 2) << "\n"; 00038 indent(out, indent_level) << "}\n"; 00039 }