- Timestamp:
- Feb 5, 2009, 12:25:30 PM (15 years ago)
- File:
-
- 1 edited
Legend:
- Unmodified
- Added
- Removed
-
trunk/source/visualization/OpenGL/src/G4OpenGLXViewerMessenger.cc
r529 r916 96 96 if (command == fpCommandPrintEPS) 97 97 { 98 // Keep copy of print_stringto preserve Xm behaviour...99 char* tmp_string = new char[50];100 strcpy (tmp_string, pViewer->print_string); 98 // Keep copy of fPrintFilename to preserve Xm behaviour... 99 std::string tmp_string = pViewer->fPrintFilename; 100 101 101 // Make new print string... 102 102 static G4int file_count = 0; 103 103 std::ostringstream oss; 104 104 oss << "G4OpenGL_" << file_count++ << ".eps"; 105 strcpy (pViewer->print_string,oss.str().c_str());105 pViewer->fPrintFilename = std::string (oss.str().c_str()); 106 106 // Print eps file... 107 107 pViewer->print(); 108 // Restore print_string for Xm... 109 strcpy (pViewer->print_string, tmp_string); 110 delete tmp_string; 108 // Restore fPrintFilename for Xm... 109 pViewer->fPrintFilename = tmp_string; 111 110 } 112 111
Note: See TracChangeset
for help on using the changeset viewer.