|
From: <ai...@us...> - 2010-10-22 00:25:44
|
Revision: 11269
http://plplot.svn.sourceforge.net/plplot/?rev=11269&view=rev
Author: airwin
Date: 2010-10-22 00:25:36 +0000 (Fri, 22 Oct 2010)
Log Message:
-----------
Convert from /* ... */ commentary style to // style for all C (as
opposed to C++) headers. The results pass a number of tests that are
mentioned on list.
ToDo: So far we have only converted C code in src and include to the
new commentary style. Those are obviously really important cases, but
we still have lots more C and C++ code (e.g., in lib, bindings,
drivers, and examples) that needs to be changed to the new commentary
style.
Modified Paths:
--------------
trunk/include/dirent_msvc.h
trunk/include/disptab.h
trunk/include/drivers.h
trunk/include/gcw.h
trunk/include/ltdl_win32.h
trunk/include/metadefs.h
trunk/include/moc_files.h.in
trunk/include/pdf.h
trunk/include/plConfig.h.cmake
trunk/include/plDevs.h.cmake
trunk/include/plcore.h
trunk/include/pldebug.h
trunk/include/pldll.h.in
trunk/include/plevent.h
trunk/include/plfci-truetype.h
trunk/include/plfci-type1.h
trunk/include/plfreetype.h
trunk/include/plplot.h
trunk/include/plplotP.h
trunk/include/plplotcanvas-hacktext.h
trunk/include/plplotcanvas.h
trunk/include/plstrm.h
trunk/include/plunicode-type1.h
trunk/include/plxwd.h
trunk/include/ps.h
Modified: trunk/include/dirent_msvc.h
===================================================================
--- trunk/include/dirent_msvc.h 2010-10-22 00:17:31 UTC (rev 11268)
+++ trunk/include/dirent_msvc.h 2010-10-22 00:25:36 UTC (rev 11269)
@@ -1,58 +1,58 @@
-/*
- * dirent.h - dirent API for Microsoft Visual Studio
- *
- * Copyright (C) 2006 Toni Ronkko
- *
- * Permission is hereby granted, free of charge, to any person obtaining
- * a copy of this software and associated documentation files (the
- * ``Software''), to deal in the Software without restriction, including
- * without limitation the rights to use, copy, modify, merge, publish,
- * distribute, sublicense, and/or sell copies of the Software, and to
- * permit persons to whom the Software is furnished to do so, subject to
- * the following conditions:
- *
- * The above copyright notice and this permission notice shall be included
- * in all copies or substantial portions of the Software.
- *
- * THE SOFTWARE IS PROVIDED ``AS IS'', WITHOUT WARRANTY OF ANY KIND, EXPRESS
- * OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF
- * MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT.
- * IN NO EVENT SHALL TONI RONKKO BE LIABLE FOR ANY CLAIM, DAMAGES OR
- * OTHER LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE,
- * ARISING FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR
- * OTHER DEALINGS IN THE SOFTWARE.
- *
- *
- * Jan 18, 2008, Toni Ronkko
- * Using FindFirstFileA and WIN32_FIND_DATAA to avoid converting string
- * between multi-byte and unicode representations. This makes the
- * code simpler and also allows the code to be compiled under MingW. Thanks
- * to Azriel Fasten for the suggestion.
- *
- * Mar 4, 2007, Toni Ronkko
- * Bug fix: due to the strncpy_s() function this file only compiled in
- * Visual Studio 2005. Using the new string functions only when the
- * compiler version allows.
- *
- * Nov 2, 2006, Toni Ronkko
- * Major update: removed support for Watcom C, MS-DOS and Turbo C to
- * simplify the file, updated the code to compile cleanly on Visual
- * Studio 2005 with both unicode and multi-byte character strings,
- * removed rewinddir() as it had a bug.
- *
- * Aug 20, 2006, Toni Ronkko
- * Removed all remarks about MSVC 1.0, which is antiqued now. Simplified
- * comments by removing SGML tags.
- *
- * May 14 2002, Toni Ronkko
- * Embedded the function definitions directly to the header so that no
- * source modules need to be included in the Visual Studio project. Removed
- * all the dependencies to other projects so that this very header can be
- * used independently.
- *
- * May 28 1998, Toni Ronkko
- * First version.
- */
+//
+// dirent.h - dirent API for Microsoft Visual Studio
+//
+// Copyright (C) 2006 Toni Ronkko
+//
+// Permission is hereby granted, free of charge, to any person obtaining
+// a copy of this software and associated documentation files (the
+// ``Software''), to deal in the Software without restriction, including
+// without limitation the rights to use, copy, modify, merge, publish,
+// distribute, sublicense, and/or sell copies of the Software, and to
+// permit persons to whom the Software is furnished to do so, subject to
+// the following conditions:
+//
+// The above copyright notice and this permission notice shall be included
+// in all copies or substantial portions of the Software.
+//
+// THE SOFTWARE IS PROVIDED ``AS IS'', WITHOUT WARRANTY OF ANY KIND, EXPRESS
+// OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF
+// MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT.
+// IN NO EVENT SHALL TONI RONKKO BE LIABLE FOR ANY CLAIM, DAMAGES OR
+// OTHER LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE,
+// ARISING FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR
+// OTHER DEALINGS IN THE SOFTWARE.
+//
+//
+// Jan 18, 2008, Toni Ronkko
+// Using FindFirstFileA and WIN32_FIND_DATAA to avoid converting string
+// between multi-byte and unicode representations. This makes the
+// code simpler and also allows the code to be compiled under MingW. Thanks
+// to Azriel Fasten for the suggestion.
+//
+// Mar 4, 2007, Toni Ronkko
+// Bug fix: due to the strncpy_s() function this file only compiled in
+// Visual Studio 2005. Using the new string functions only when the
+// compiler version allows.
+//
+// Nov 2, 2006, Toni Ronkko
+// Major update: removed support for Watcom C, MS-DOS and Turbo C to
+// simplify the file, updated the code to compile cleanly on Visual
+// Studio 2005 with both unicode and multi-byte character strings,
+// removed rewinddir() as it had a bug.
+//
+// Aug 20, 2006, Toni Ronkko
+// Removed all remarks about MSVC 1.0, which is antiqued now. Simplified
+// comments by removing SGML tags.
+//
+// May 14 2002, Toni Ronkko
+// Embedded the function definitions directly to the header so that no
+// source modules need to be included in the Visual Studio project. Removed
+// all the dependencies to other projects so that this very header can be
+// used independently.
+//
+// May 28 1998, Toni Ronkko
+// First version.
+//
#ifndef DIRENT_H
#define DIRENT_H
@@ -63,26 +63,26 @@
typedef struct dirent
{
- /* name of current directory entry (a multi-byte character string) */
+ // name of current directory entry (a multi-byte character string)
char d_name[MAX_PATH + 1];
- /* file attributes */
+ // file attributes
WIN32_FIND_DATAA data;
} dirent;
typedef struct DIR
{
- /* current directory entry */
+ // current directory entry
dirent current;
- /* is there an un-processed entry in current? */
+ // is there an un-processed entry in current?
int cached;
- /* file search handle */
+ // file search handle
HANDLE search_handle;
- /* search pattern (3 = zero terminator + pattern "\\*") */
+ // search pattern (3 = zero terminator + pattern "\\*")
char patt[MAX_PATH + 3];
} DIR;
@@ -92,7 +92,7 @@
static int closedir( DIR *dirp );
-/* use the new safe string functions introduced in Visual Studio 2005 */
+// use the new safe string functions introduced in Visual Studio 2005
#if defined ( _MSC_VER ) && _MSC_VER >= 1400
# define STRNCPY( dest, src, size ) strncpy_s( ( dest ), ( size ), ( src ), _TRUNCATE )
#else
@@ -100,11 +100,11 @@
#endif
-/*
- * Open directory stream DIRNAME for read and return a pointer to the
- * internal working area that is used to retrieve individual directory
- * entries.
- */
+//
+// Open directory stream DIRNAME for read and return a pointer to the
+// internal working area that is used to retrieve individual directory
+// entries.
+//
static DIR*
opendir(
const char *dirname )
@@ -113,17 +113,17 @@
assert( dirname != NULL );
assert( strlen( dirname ) < MAX_PATH );
- /* construct new DIR structure */
+ // construct new DIR structure
dirp = (DIR*) malloc( sizeof ( struct DIR ) );
if ( dirp != NULL )
{
char *p;
- /* take directory name... */
+ // take directory name...
STRNCPY( dirp->patt, dirname, sizeof ( dirp->patt ) );
dirp->patt[MAX_PATH] = '\0';
- /* ... and append search pattern to it */
+ // ... and append search pattern to it
p = strchr( dirp->patt, '\0' );
if ( dirp->patt < p && *( p - 1 ) != '\\' && *( p - 1 ) != ':' )
{
@@ -132,29 +132,29 @@
*p++ = '*';
*p = '\0';
- /* open stream and retrieve first file */
+ // open stream and retrieve first file
dirp->search_handle = FindFirstFileA( dirp->patt, &dirp->current.data );
if ( dirp->search_handle == INVALID_HANDLE_VALUE )
{
- /* invalid search pattern? */
+ // invalid search pattern?
free( dirp );
return NULL;
}
- /* there is an un-processed directory entry in memory now */
+ // there is an un-processed directory entry in memory now
dirp->cached = 1;
}
return dirp;
}
-/*
- * Read a directory entry, and return a pointer to a dirent structure
- * containing the name of the entry in d_name field. Individual directory
- * entries returned by this very function include regular files,
- * sub-directories, pseudo-directories "." and "..", but also volume labels,
- * hidden files and system files may be returned.
- */
+//
+// Read a directory entry, and return a pointer to a dirent structure
+// containing the name of the entry in d_name field. Individual directory
+// entries returned by this very function include regular files,
+// sub-directories, pseudo-directories "." and "..", but also volume labels,
+// hidden files and system files may be returned.
+//
static struct dirent *
readdir(
DIR *dirp )
@@ -163,29 +163,29 @@
if ( dirp->search_handle == INVALID_HANDLE_VALUE )
{
- /* directory stream was opened/rewound incorrectly or it ended normally */
+ // directory stream was opened/rewound incorrectly or it ended normally
return NULL;
}
- /* get next directory entry */
+ // get next directory entry
if ( dirp->cached != 0 )
{
- /* a valid directory entry already in memory */
+ // a valid directory entry already in memory
dirp->cached = 0;
}
else
{
- /* read next directory entry from disk */
+ // read next directory entry from disk
if ( FindNextFileA( dirp->search_handle, &dirp->current.data ) == FALSE )
{
- /* the very last file has been processed or an error occured */
+ // the very last file has been processed or an error occured
FindClose( dirp->search_handle );
dirp->search_handle = INVALID_HANDLE_VALUE;
return NULL;
}
}
- /* copy as a multibyte character string */
+ // copy as a multibyte character string
STRNCPY( dirp->current.d_name, dirp->current.data.cFileName, sizeof ( dirp->current.d_name ) );
dirp->current.d_name[MAX_PATH] = '\0';
@@ -193,28 +193,28 @@
}
-/*
- * Close directory stream opened by opendir() function. Close of the
- * directory stream invalidates the DIR structure as well as any previously
- * read directory entry.
- */
+//
+// Close directory stream opened by opendir() function. Close of the
+// directory stream invalidates the DIR structure as well as any previously
+// read directory entry.
+//
static int
closedir(
DIR *dirp )
{
assert( dirp != NULL );
- /* release search handle */
+ // release search handle
if ( dirp->search_handle != INVALID_HANDLE_VALUE )
{
FindClose( dirp->search_handle );
dirp->search_handle = INVALID_HANDLE_VALUE;
}
- /* release directory handle */
+ // release directory handle
free( dirp );
return 0;
}
-#endif /*DIRENT_H*/
+#endif //DIRENT_H
Modified: trunk/include/disptab.h
===================================================================
--- trunk/include/disptab.h 2010-10-22 00:17:31 UTC (rev 11268)
+++ trunk/include/disptab.h 2010-10-22 00:25:36 UTC (rev 11269)
@@ -1,7 +1,7 @@
-/* $Id$
- *
- * Defines the data structure which holds the driver functions.
- */
+// $Id$
+//
+// Defines the data structure which holds the driver functions.
+//
#ifndef __DISPATCH_H__
#define __DISPATCH_H__
@@ -17,54 +17,54 @@
plDevType_Null = -1
};
-/*--------------------------------------------------------------------------*\
- * Define structure containing pointers to device dependent functions.
- *
- * pl_MenuStr Pointer to string that is printed in device menu.
- *
- * pl_DevName A short device "name" for device selection by name.
- *
- * pl_type 0 for file-oriented device, 1 for interactive
- * (the null driver uses -1 here)
- *
- * pl_seq The sequence number for ordering the presentation list of the
- * available drivers. This is an ordering only, not an absolute
- * position in the list.
- *
- * pl_init Initialize device. This routine may also prompt the user
- * for certain device parameters or open a graphics file
- * (see note). Called only once to set things up. Certain
- * options such as familying and resolution (dots/mm) should
- * be set up before calling this routine (note: some drivers
- * ignore these).
- *
- * pl_line Draws a line between two points.
- *
- * pl_polyline Draws a polyline (no broken segments).
- *
- * pl_eop Finishes out current page (see note).
- *
- * pl_bop Set up for plotting on a new page. May also open a new
- * a new graphics file (see note).
- *
- * pl_tidy Tidy up. May close graphics file (see note).
- *
- * pl_state Handle change in PLStream state
- * (color, pen width, fill attribute, etc).
- *
- * pl_esc Escape function for driver-specific commands.
- *
- *
- * Notes:
- *
- * Most devices allow multi-page plots to be stored in a single graphics
- * file, in which case the graphics file should be opened in the pl_init()
- * routine, closed in pl_tidy(), and page advances done by calling pl_eop
- * and pl_bop() in sequence. If multi-page plots need to be stored in
- * different files then pl_bop() should open the file and pl_eop() should
- * close it. Do NOT open files in both pl_init() and pl_bop() or close
- * files in both pl_eop() and pl_tidy().
- \*--------------------------------------------------------------------------*/
+//--------------------------------------------------------------------------
+// Define structure containing pointers to device dependent functions.
+//
+// pl_MenuStr Pointer to string that is printed in device menu.
+//
+// pl_DevName A short device "name" for device selection by name.
+//
+// pl_type 0 for file-oriented device, 1 for interactive
+// (the null driver uses -1 here)
+//
+// pl_seq The sequence number for ordering the presentation list of the
+// available drivers. This is an ordering only, not an absolute
+// position in the list.
+//
+// pl_init Initialize device. This routine may also prompt the user
+// for certain device parameters or open a graphics file
+// (see note). Called only once to set things up. Certain
+// options such as familying and resolution (dots/mm) should
+// be set up before calling this routine (note: some drivers
+// ignore these).
+//
+// pl_line Draws a line between two points.
+//
+// pl_polyline Draws a polyline (no broken segments).
+//
+// pl_eop Finishes out current page (see note).
+//
+// pl_bop Set up for plotting on a new page. May also open a new
+// a new graphics file (see note).
+//
+// pl_tidy Tidy up. May close graphics file (see note).
+//
+// pl_state Handle change in PLStream state
+// (color, pen width, fill attribute, etc).
+//
+// pl_esc Escape function for driver-specific commands.
+//
+//
+// Notes:
+//
+// Most devices allow multi-page plots to be stored in a single graphics
+// file, in which case the graphics file should be opened in the pl_init()
+// routine, closed in pl_tidy(), and page advances done by calling pl_eop
+// and pl_bop() in sequence. If multi-page plots need to be stored in
+// different files then pl_bop() should open the file and pl_eop() should
+// close it. Do NOT open files in both pl_init() and pl_bop() or close
+// files in both pl_eop() and pl_tidy().
+//--------------------------------------------------------------------------
typedef void ( *plD_init_fp )( struct PLStream_struct * );
typedef void ( *plD_line_fp )( struct PLStream_struct *, short, short, short, short );
@@ -91,4 +91,4 @@
plD_esc_fp pl_esc;
} PLDispatchTable;
-#endif /* __DISPATCH_H__ */
+#endif // __DISPATCH_H__
Modified: trunk/include/drivers.h
===================================================================
--- trunk/include/drivers.h 2010-10-22 00:17:31 UTC (rev 11268)
+++ trunk/include/drivers.h 2010-10-22 00:25:36 UTC (rev 11269)
@@ -1,28 +1,28 @@
-/* $Id$
- *
- * Contains all prototypes for driver functions.
- *
- * Copyright (C) 2004 Andrew Roach
- * Copyright (C) 2005 Thomas J. Duck
- * Copyright (C) 2006 Andrew Ross
- *
- * This file is part of PLplot.
- *
- * PLplot is free software; you can redistribute it and/or modify
- * it under the terms of the GNU Library General Public License as published
- * by the Free Software Foundation; either version 2 of the License, or
- * (at your option) any later version.
- *
- * PLplot is distributed in the hope that it will be useful,
- * but WITHOUT ANY WARRANTY; without even the implied warranty of
- * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
- * GNU Library General Public License for more details.
- *
- * You should have received a copy of the GNU Library General Public License
- * along with PLplot; if not, write to the Free Software
- * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301 USA
- *
- */
+// $Id$
+//
+// Contains all prototypes for driver functions.
+//
+// Copyright (C) 2004 Andrew Roach
+// Copyright (C) 2005 Thomas J. Duck
+// Copyright (C) 2006 Andrew Ross
+//
+// This file is part of PLplot.
+//
+// PLplot is free software; you can redistribute it and/or modify
+// it under the terms of the GNU Library General Public License as published
+// by the Free Software Foundation; either version 2 of the License, or
+// (at your option) any later version.
+//
+// PLplot is distributed in the hope that it will be useful,
+// but WITHOUT ANY WARRANTY; without even the implied warranty of
+// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
+// GNU Library General Public License for more details.
+//
+// You should have received a copy of the GNU Library General Public License
+// along with PLplot; if not, write to the Free Software
+// Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301 USA
+//
+//
#ifndef __DRIVERS_H__
#define __DRIVERS_H__
@@ -110,7 +110,7 @@
PLDLLIMPEXP_DRIVER void plD_dispatch_init_extqt( PLDispatchTable *pdt );
PLDLLIMPEXP_DRIVER void plD_dispatch_init_memqt( PLDispatchTable *pdt );
-/* Prototypes for plot buffer calls. */
+// Prototypes for plot buffer calls.
void plbuf_init( PLStream * );
void plbuf_line( PLStream *, short, short, short, short );
@@ -130,4 +130,4 @@
}
#endif
-#endif /* __DRIVERS_H__ */
+#endif // __DRIVERS_H__
Modified: trunk/include/gcw.h
===================================================================
--- trunk/include/gcw.h 2010-10-22 00:17:31 UTC (rev 11268)
+++ trunk/include/gcw.h 2010-10-22 00:25:36 UTC (rev 11269)
@@ -1,26 +1,26 @@
-/* gcw - PLplot Gnome Canvas Widget device driver.
- *
- * Copyright (C) 2004, 2005 Thomas J. Duck
- * Copyright (C) 2004 Rafael Laboissiere
- * All rights reserved.
- *
- * NOTICE
- *
- * This library is free software; you can redistribute it and/or
- * modify it under the terms of the GNU Lesser General Public
- * License as published by the Free Software Foundation; either
- * version 2.1 of the License, or (at your option) any later version.
- *
- * This library is distributed in the hope that it will be useful,
- * but WITHOUT ANY WARRANTY; without even the implied warranty of
- * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
- * Lesser General Public License for more details.
- *
- * You should have received a copy of the GNU Lesser General Public
- * License along with this library; if not, write to the Free Software
- * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301
- * USA
- */
+// gcw - PLplot Gnome Canvas Widget device driver.
+//
+// Copyright (C) 2004, 2005 Thomas J. Duck
+// Copyright (C) 2004 Rafael Laboissiere
+// All rights reserved.
+//
+// NOTICE
+//
+// This library is free software; you can redistribute it and/or
+// modify it under the terms of the GNU Lesser General Public
+// License as published by the Free Software Foundation; either
+// version 2.1 of the License, or (at your option) any later version.
+//
+// This library is distributed in the hope that it will be useful,
+// but WITHOUT ANY WARRANTY; without even the implied warranty of
+// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
+// Lesser General Public License for more details.
+//
+// You should have received a copy of the GNU Lesser General Public
+// License along with this library; if not, write to the Free Software
+// Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301
+// USA
+//
#ifndef __GCW_H__
#define __GCW_H__
@@ -40,98 +40,98 @@
#include <libgnomeprint/gnome-print.h>
-/* #define DEBUG_GCW_1 */
-/* #define DEBUG_GCW_2 */
-/* #define ASSERT_GCW */
+// #define DEBUG_GCW_1
+// #define DEBUG_GCW_2
+// #define ASSERT_GCW
-/*=========================================================================*/
-/* GcwPLdev - the PLplot device structure for the GCW driver */
+//=========================================================================
+// GcwPLdev - the PLplot device structure for the GCW driver
typedef struct
{
- GnomeCanvas * canvas; /* The canvas to draw on */
- GdkPixmap * background; /* The background */
- GdkGC * gc; /* A graphics context for the pixmap */
+ GnomeCanvas * canvas; // The canvas to draw on
+ GdkPixmap * background; // The background
+ GdkGC * gc; // A graphics context for the pixmap
- GnomeCanvasGroup* group_visible; /* Visible group, removed at next eop */
- GnomeCanvasGroup* group_hidden; /* Hidden group --> visible at eop */
- GnomeCanvasGroup* group_persistent; /* Persistent group, at from and never erased */
+ GnomeCanvasGroup* group_visible; // Visible group, removed at next eop
+ GnomeCanvasGroup* group_hidden; // Hidden group --> visible at eop
+ GnomeCanvasGroup* group_persistent; // Persistent group, at from and never erased
- gboolean use_persistence; /* Flags the persistent group should be used,
- * and that it and the background should not be
- * erased when the page is advanced.
- */
+ gboolean use_persistence; // Flags the persistent group should be used,
+ // and that it and the background should not be
+ // erased when the page is advanced.
+ //
- GtkWidget * window; /* A window used in standalone mode */
- GtkWidget * notebook; /* A notebook pager in the window */
- GtkWidget * statusbar; /* A statusbar for the window */
- GtkWidget * filew; /* A file widget chooser when Save is pressed */
+ GtkWidget * window; // A window used in standalone mode
+ GtkWidget * notebook; // A notebook pager in the window
+ GtkWidget * statusbar; // A statusbar for the window
+ GtkWidget * filew; // A file widget chooser when Save is pressed
- guint32 color; /* Current pen color */
- GdkColor bgcolor; /* Background color (shouldn't change) */
- GdkColormap* colormap; /* The gdk colormap for the canvas */
+ guint32 color; // Current pen color
+ GdkColor bgcolor; // Background color (shouldn't change)
+ GdkColormap* colormap; // The gdk colormap for the canvas
- PLINT width; /* Width of the canvas in device pixels */
- PLINT height; /* Height of the canvas in device pixels */
+ PLINT width; // Width of the canvas in device pixels
+ PLINT height; // Height of the canvas in device pixels
- PLINT pen_color; /* Current pen color */
- PLINT pen_width; /* Current pen width */
+ PLINT pen_color; // Current pen color
+ PLINT pen_width; // Current pen width
- gboolean use_pixmap; /* Flags pixmap use for lines and fills */
- gboolean pixmap_has_data; /* Flags that the pixmap has data */
+ gboolean use_pixmap; // Flags pixmap use for lines and fills
+ gboolean pixmap_has_data; // Flags that the pixmap has data
- gboolean plstate_width; /* Flags indicating change of state before */
- gboolean plstate_color0; /* device is fully initialized */
+ gboolean plstate_width; // Flags indicating change of state before
+ gboolean plstate_color0; // device is fully initialized
gboolean plstate_color1;
- gboolean allow_resize; /* Flags whether device resizing is allowed */
+ gboolean allow_resize; // Flags whether device resizing is allowed
} GcwPLdev;
-/*=========================================================================*/
-/* Physical dimension constants used by the driver */
+//=========================================================================
+// Physical dimension constants used by the driver
-/* Virtual coordinate scaling parameter, used to do calculations at
- * higher resolution. Chosen to be 32 for consistency with the PLplot
- * metafile (see plplotP.h).
- *
- * The trick here is to do everything in device coordinates on the driver
- * side, but report/receive everything in virtual coordinates to/from the
- * PLplot core.
- */
+// Virtual coordinate scaling parameter, used to do calculations at
+// higher resolution. Chosen to be 32 for consistency with the PLplot
+// metafile (see plplotP.h).
+//
+// The trick here is to do everything in device coordinates on the driver
+// side, but report/receive everything in virtual coordinates to/from the
+// PLplot core.
+//
#define VSCALE ( 32. )
-/* pixels per mm */
+// pixels per mm
#define DEVICE_PIXELS_PER_MM ( 3.4 )
#define VIRTUAL_PIXELS_PER_MM ( DEVICE_PIXELS_PER_MM * VSCALE )
-/* mm per inch */
+// mm per inch
#define MM_PER_IN ( 25.4 )
-/* pixels per inch */
+// pixels per inch
#define DEVICE_PIXELS_PER_IN ( DEVICE_PIXELS_PER_MM * MM_PER_IN )
#define VIRTUAL_PIXELS_PER_IN ( VIRTUAL_PIXELS_PER_MM * MM_PER_IN )
-/* Default dimensions of the canvas (in inches) */
+// Default dimensions of the canvas (in inches)
#define CANVAS_WIDTH ( 10. )
#define CANVAS_HEIGHT ( 7.5 )
-/* The zoom factor for 100% zoom in */
+// The zoom factor for 100% zoom in
#define ZOOM100 ( 1.0 )
#define ZOOMSTEP ( 1.25 )
-/*=========================================================================*/
-/* GCW "Gnome Canvas Widget" Library prototypes (see gcw-lib.c) */
+//=========================================================================
+// GCW "Gnome Canvas Widget" Library prototypes (see gcw-lib.c)
-/* Public_functions */
+// Public_functions
void gcw_use_text( PLINT use_text );
void gcw_use_pixmap( PLINT use_pixmap );
void gcw_use_hrshsym( PLINT use_hrshsym );
-/* Private functions */
+// Private functions
void gcw_debug( char* msg );
PLDLLIMPEXP_GNOME2 void gcw_set_gdk_color();
@@ -143,4 +143,4 @@
void gcw_set_canvas_zoom( GnomeCanvas* canvas, PLFLT magnification );
void gcw_use_persistence( PLINT use_persistence );
-#endif /* __GCW_H__ */
+#endif // __GCW_H__
Modified: trunk/include/ltdl_win32.h
===================================================================
--- trunk/include/ltdl_win32.h 2010-10-22 00:17:31 UTC (rev 11268)
+++ trunk/include/ltdl_win32.h 2010-10-22 00:25:36 UTC (rev 11269)
@@ -1,26 +1,26 @@
-/* $Id$
- *
- * Contains all prototypes for driver functions.
- *
- * Copyright (C) 2008 Werner Smekal
- *
- * This file is part of PLplot.
- *
- * PLplot is free software; you can redistribute it and/or modify
- * it under the terms of the GNU Library General Public License as published
- * by the Free Software Foundation; either version 2 of the License, or
- * (at your option) any later version.
- *
- * PLplot is distributed in the hope that it will be useful,
- * but WITHOUT ANY WARRANTY; without even the implied warranty of
- * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
- * GNU Library General Public License for more details.
- *
- * You should have received a copy of the GNU Library General Public License
- * along with PLplot; if not, write to the Free Software
- * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301 USA
- *
- */
+// $Id$
+//
+// Contains all prototypes for driver functions.
+//
+// Copyright (C) 2008 Werner Smekal
+//
+// This file is part of PLplot.
+//
+// PLplot is free software; you can redistribute it and/or modify
+// it under the terms of the GNU Library General Public License as published
+// by the Free Software Foundation; either version 2 of the License, or
+// (at your option) any later version.
+//
+// PLplot is distributed in the hope that it will be useful,
+// but WITHOUT ANY WARRANTY; without even the implied warranty of
+// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
+// GNU Library General Public License for more details.
+//
+// You should have received a copy of the GNU Library General Public License
+// along with PLplot; if not, write to the Free Software
+// Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301 USA
+//
+//
#ifndef __LTDL_WIN32_H__
#define __LTDL_WIN32_H__
@@ -46,4 +46,4 @@
PLDLLIMPEXP void* lt_dlsym( lt_dlhandle dlhandle, const char* symbol );
-#endif /* __LTDL_WIN32_H__ */
+#endif // __LTDL_WIN32_H__
Modified: trunk/include/metadefs.h
===================================================================
--- trunk/include/metadefs.h 2010-10-22 00:17:31 UTC (rev 11268)
+++ trunk/include/metadefs.h 2010-10-22 00:25:36 UTC (rev 11269)
@@ -1,41 +1,41 @@
-/* $Id$
- *
- * Geoffrey Furnish
- * 5 May 1991
- *
- * This file contains definitions of constants and structures which
- * are needed by the PLplot metafile writer and renderer.
- */
+// $Id$
+//
+// Geoffrey Furnish
+// 5 May 1991
+//
+// This file contains definitions of constants and structures which
+// are needed by the PLplot metafile writer and renderer.
+//
-/*
- * PLMETA_HEADER holds the magic string at head of metafile.
- * PLMETA_VERSION holds the version number (year & letter).
- *
- * Note: All strings written into the file header are limited to a maximum
- * of 80 characters.
- */
+//
+// PLMETA_HEADER holds the magic string at head of metafile.
+// PLMETA_VERSION holds the version number (year & letter).
+//
+// Note: All strings written into the file header are limited to a maximum
+// of 80 characters.
+//
#define PLMETA_HEADER "PLPLOT"
#define PLMETA_VERSION "2005a"
-/* These are used by the TK driver client/server code */
+// These are used by the TK driver client/server code
#define PLSERV_HEADER "PLPLOT"
#define PLSERV_VERSION "2005b"
-/* Symbolic constants for old metafile versions (prior to 1992a). */
-/* Now these are stored in the metafile header. */
+// Symbolic constants for old metafile versions (prior to 1992a).
+// Now these are stored in the metafile header.
#define PLMETA_X_OLD 10000
#define PLMETA_Y_OLD 10000
-/* Virtual dots/mm for our virtual display space. */
+// Virtual dots/mm for our virtual display space.
#define PIXEL_RES_X_OLD 42
#define PIXEL_RES_Y_OLD 56
-/* Macros to make it easier to abort on nonzero return code */
-/* Can't call plexit on a write failure since that would be circular */
+// Macros to make it easier to abort on nonzero return code
+// Can't call plexit on a write failure since that would be circular
#define plm_wr( code ) \
if ( code ) { fprintf( stderr, "Unable to write to MetaFile\n" ); exit( 1 ); }
@@ -43,30 +43,30 @@
#define plm_rd( code ) \
if ( code ) plexit( "Unable to read from MetaFile" )
-/*
- * Metafile commands.
- *
- *** NOTICE !!! ***
- * If you change ANY of the following, you will wreck backward
- * backward compatibility with old metafiles. You may add, but do
- * NOT delete !!!
- */
+//
+// Metafile commands.
+//
+//** NOTICE !!! ***
+// If you change ANY of the following, you will wreck backward
+// backward compatibility with old metafiles. You may add, but do
+// NOT delete !!!
+//
#define INITIALIZE 1
#define CLOSE 2
-#define SWITCH_TO_TEXT 3 /* Obsolete, replaced by ESCAPE */
-#define SWITCH_TO_GRAPH 4 /* Obsolete, replaced by ESCAPE */
+#define SWITCH_TO_TEXT 3 // Obsolete, replaced by ESCAPE
+#define SWITCH_TO_GRAPH 4 // Obsolete, replaced by ESCAPE
#define EOP 5
#define BOP 6
-#define NEW_COLOR 7 /* Obsolete, replaced by CHANGE_STATE */
-#define NEW_WIDTH 8 /* Obsolete, replaced by CHANGE_STATE */
+#define NEW_COLOR 7 // Obsolete, replaced by CHANGE_STATE
+#define NEW_WIDTH 8 // Obsolete, replaced by CHANGE_STATE
#define LINE 9
#define LINETO 10
#define ESCAPE 11
-#define ADVANCE 12 /* Obsolete, BOP/EOP used instead */
+#define ADVANCE 12 // Obsolete, BOP/EOP used instead
#define POLYLINE 13
#define NEW_COLOR0 NEW_COLOR
#define NEW_COLOR1 14
#define CHANGE_STATE 15
-#define BOP0 16 /* First BOP in a file */
+#define BOP0 16 // First BOP in a file
#define END_OF_FIELD 255
Modified: trunk/include/moc_files.h.in
===================================================================
--- trunk/include/moc_files.h.in 2010-10-22 00:17:31 UTC (rev 11268)
+++ trunk/include/moc_files.h.in 2010-10-22 00:25:36 UTC (rev 11269)
@@ -1,6 +1,6 @@
-/* Configured header file listing the moc-generated files to include in plqt.cpp. */
+// Configured header file listing the moc-generated files to include in plqt.cpp.
#ifndef __MOC_FILES_H__
#define __MOC_FILES_H__
#include "@QT_MOC_OUTFILES@"
-#endif /* __MOC_FILES_H__i */
+#endif // __MOC_FILES_H__i
Modified: trunk/include/pdf.h
===================================================================
--- trunk/include/pdf.h 2010-10-22 00:17:31 UTC (rev 11268)
+++ trunk/include/pdf.h 2010-10-22 00:25:36 UTC (rev 11269)
@@ -1,28 +1,28 @@
-/* $Id$
- *
- * Copyright (C) 1992 by Maurice J. LeBrun
- *
- * Macros and prototypes for the PDF package.
- *
- * This software may be freely copied, modified and redistributed without
- * fee provided that this copyright notice is preserved intact on all
- * copies and modified copies.
- *
- * There is no warranty or other guarantee of fitness of this software.
- * It is provided solely "as is". The author(s) disclaim(s) all
- * responsibility and liability with respect to this software's usage or
- * its effect upon hardware or computer systems.
- */
+// $Id$
+//
+// Copyright (C) 1992 by Maurice J. LeBrun
+//
+// Macros and prototypes for the PDF package.
+//
+// This software may be freely copied, modified and redistributed without
+// fee provided that this copyright notice is preserved intact on all
+// copies and modified copies.
+//
+// There is no warranty or other guarantee of fitness of this software.
+// It is provided solely "as is". The author(s) disclaim(s) all
+// responsibility and liability with respect to this software's usage or
+// its effect upon hardware or computer systems.
+//
#ifndef __PDF_H__
#define __PDF_H__
-/*--------------------------------------------------------------------------*\
- * dll functions
- \*--------------------------------------------------------------------------*/
+//--------------------------------------------------------------------------
+// dll functions
+//--------------------------------------------------------------------------
#include "pldll.h"
-/* Some unsigned types */
+// Some unsigned types
#ifndef U_CHAR
#define U_CHAR unsigned char
@@ -44,45 +44,45 @@
#include <tcl.h>
#endif
-/* PDFstrm definition */
-/* The low level PDF i/o routines use the transfer method appropriate for */
-/* the first non-null type below */
+// PDFstrm definition
+// The low level PDF i/o routines use the transfer method appropriate for
+// the first non-null type below
typedef struct
{
- FILE *file; /* Filesystem */
- unsigned char *buffer; /* Memory buffer */
+ FILE *file; // Filesystem
+ unsigned char *buffer; // Memory buffer
#ifdef PLPLOT_USE_TCL_CHANNELS
- Tcl_Channel tclChan; /* Tcl channel */
+ Tcl_Channel tclChan; // Tcl channel
#endif
- long bp, bufmax; /* Buffer pointer and max size */
+ long bp, bufmax; // Buffer pointer and max size
} PDFstrm;
-/* Info for the i/o device. Only used by Tcl/TK/dp drivers for now */
+// Info for the i/o device. Only used by Tcl/TK/dp drivers for now
typedef struct
{
- int fd; /* I/O device file descriptor */
- FILE *file; /* File handle */
- const char *fileName; /* Fifo or socket name (if needed) */
- const char *fileHandle; /* Handle for use from interpreter */
- int type; /* Communication channel type */
- const char *typeName; /* As above, but in string form */
+ int fd; // I/O device file descriptor
+ FILE *file; // File handle
+ const char *fileName; // Fifo or socket name (if needed)
+ const char *fileHandle; // Handle for use from interpreter
+ int type; // Communication channel type
+ const char *typeName; // As above, but in string form
} PLiodev;
-/* Error numbers */
+// Error numbers
-#define PDF_ERROR 1 /* Unknown error */
-#define PDF_FNOPEN 2 /* File not open */
-#define PDF_FAOPEN 3 /* File already open */
-#define PDF_BADUN 4 /* Bad unit number */
-#define PDF_BADNBITS 5 /* Invalid # of bits */
-#define PDF_RDERR 6 /* Read error */
-#define PDF_WRERR 7 /* Write error */
-#define PDF_NOTPDF 8 /* Not a valid PDF file */
+#define PDF_ERROR 1 // Unknown error
+#define PDF_FNOPEN 2 // File not open
+#define PDF_FAOPEN 3 // File already open
+#define PDF_BADUN 4 // Bad unit number
+#define PDF_BADNBITS 5 // Invalid # of bits
+#define PDF_RDERR 6 // Read error
+#define PDF_WRERR 7 // Write error
+#define PDF_NOTPDF 8 // Not a valid PDF file
-/* Prototypes */
-/* Use a wrapper for the prototypes for use from K&R C */
+// Prototypes
+// Use a wrapper for the prototypes for use from K&R C
void pdf_set PLARGS( ( char *option, int value ) );
PLDLLIMPEXP PDFstrm *pdf_fopen PLARGS( ( const char *fileName, const char *mode ) );
@@ -111,4 +111,4 @@
PLDLLIMPEXP int pdf_wr_ieeef PLARGS( ( PDFstrm * pdfs, float f ) );
PLDLLIMPEXP int pdf_rd_ieeef PLARGS( ( PDFstrm * pdfs, float *pf ) );
-#endif /* __PDF_H__ */
+#endif // __PDF_H__
Modified: trunk/include/plConfig.h.cmake
===================================================================
--- trunk/include/plConfig.h.cmake 2010-10-22 00:17:31 UTC (rev 11268)
+++ trunk/include/plConfig.h.cmake 2010-10-22 00:25:36 UTC (rev 11269)
@@ -1,50 +1,50 @@
-/* -*-C-*- */
-/* $Id$
- *
- * Maurice LeBrun
- * IFS, University of Texas at Austin
- * 18-Jul-1994
- *
- * Copyright (C) 2004, 2006, 2007, 2008, 2009 Alan W. Irwin
- * Copyright (C) 2004 Rafael Laboissiere
- * Copyright (C) 2004 Joao Cardoso
- *
- * This file is part of PLplot.
- *
- * PLplot is free software; you can redistribute it and/or modify
- * it under the terms of the GNU General Library Public License as published
- * by the Free Software Foundation; either version 2 of the License, or
- * (at your option) any later version.
- *
- * PLplot is distributed in the hope that it will be useful,
- * but WITHOUT ANY WARRANTY; without even the implied warranty of
- * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
- * GNU Library General Public License for more details.
- *
- * You should have received a copy of the GNU Library General Public License
- * along with PLplot; if not, write to the Free Software
- * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301 USA
- *
- */
+// -*-C-*-
+// $Id$
+//
+// Maurice LeBrun
+// IFS, University of Texas at Austin
+// 18-Jul-1994
+//
+// Copyright (C) 2004, 2006, 2007, 2008, 2009 Alan W. Irwin
+// Copyright (C) 2004 Rafael Laboissiere
+// Copyright (C) 2004 Joao Cardoso
+//
+// This file is part of PLplot.
+//
+// PLplot is free software; you can redistribute it and/or modify
+// it under the terms of the GNU General Library Public License as published
+// by the Free Software Foundation; either version 2 of the License, or
+// (at your option) any later version.
+//
+// PLplot is distributed in the hope that it will be useful,
+// but WITHOUT ANY WARRANTY; without even the implied warranty of
+// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
+// GNU Library General Public License for more details.
+//
+// You should have received a copy of the GNU Library General Public License
+// along with PLplot; if not, write to the Free Software
+// Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301 USA
+//
+//
-/* Configured (by CMake) macros for PLplot that are required for the
- * core build and the build of the installed
- * examples (and presumably any user applications). Therefore, the
- * configured plConfig.h should be installed. In contrast,
- * config.h.cmake (note, plConfig.h #includes config.h for
- * the core build because HAVE_CONFIG_H is #defined in that case)
- * contains configured macros that are only required for the core
- * build. Therefore, in contrast to plConfig.h, config.h should not
- * be installed.
- *
- * Maintenance issue: in makes no sense to configure duplicate macros
- * for both config.h and plConfig.h. Therefore, when adding a macro
- * decide which file to put it in depending on whether the result is
- * needed for the installed examples build or not. Furthermore, move
- * configured macros from one file to the other as needed depending on
- * that criterion, but do not copy them.
- *
- */
+// Configured (by CMake) macros for PLplot that are required for the
+// core build and the build of the installed
+// examples (and presumably any user applications). Therefore, the
+// configured plConfig.h should be installed. In contrast,
+// config.h.cmake (note, plConfig.h #includes config.h for
+// the core build because HAVE_CONFIG_H is #defined in that case)
+// contains configured macros that are only required for the core
+// build. Therefore, in contrast to plConfig.h, config.h should not
+// be installed.
+//
+// Maintenance issue: in makes no sense to configure duplicate macros
+// for both config.h and plConfig.h. Therefore, when adding a macro
+// decide which file to put it in depending on whether the result is
+// needed for the installed examples build or not. Furthermore, move
+// configured macros from one file to the other as needed depending on
+// that criterion, but do not copy them.
+//
+//
#ifndef __PLCONFIG_H__
#define __PLCONFIG_H__
@@ -53,48 +53,48 @@
# include <config.h>
#endif
-/* Define if you have c++ accessible stdint.h */
+// Define if you have c++ accessible stdint.h
#cmakedefine PL_HAVE_CXX_STDINT_H
-/* Define if snprintf is available */
+// Define if snprintf is available
#ifndef PL_HAVE_SNPRINTF
#cmakedefine PL_HAVE_SNPRINTF
#endif
-/* Define if _snprintf is available */
+// Define if _snprintf is available
#ifndef _PL_HAVE_SNPRINTF
#cmakedefine _PL_HAVE_SNPRINTF
#endif
-/* Define if isinf is available */
+// Define if isinf is available
#cmakedefine PL_HAVE_ISINF
-/* Define if _isinf is available */
+// Define if _isinf is available
#cmakedefine PL__HAVE_ISINF
-/* Define if isnan is available */
+// Define if isnan is available
#cmakedefine PL_HAVE_ISNAN
-/* Define if _isnan is available */
+// Define if _isnan is available
#cmakedefine PL__HAVE_ISNAN
-/* Define to 1 if you have the <stdint.h> header file. */
+// Define to 1 if you have the <stdint.h> header file.
#cmakedefine PL_HAVE_STDINT_H 1
-/* Define to 1 if you have the <unistd.h> header file. */
+// Define to 1 if you have the <unistd.h> header file.
#cmakedefine PL_HAVE_UNISTD_H 1
-/* Define if usleep is available */
+// Define if usleep is available
#cmakedefine PL_HAVE_USLEEP
-/* Define if you want PLplot's float type to be double */
+// Define if you want PLplot's float type to be double
#cmakedefine PL_DOUBLE
-/* Define if C++ compiler accepts using namespace */
+// Define if C++ compiler accepts using namespace
#cmakedefine PL_USE_NAMESPACE
-/* Define if isnan is present in <math.h> but not in <cmath>
- * - broken Mac OSX systems */
+// Define if isnan is present in <math.h> but not in <cmath>
+// - broken Mac OSX systems
#cmakedefine PL_BROKEN_ISNAN_CXX
-#endif /* __PLCONFIG_H__ */
+#endif // __PLCONFIG_H__
Modified: trunk/include/plDevs.h.cmake
===================================================================
--- trunk/include/plDevs.h.cmake 2010-10-22 00:17:31 UTC (rev 11268)
+++ trunk/include/plDevs.h.cmake 2010-10-22 00:25:36 UTC (rev 11269)
@@ -1,38 +1,38 @@
-/* -*-C-*- */
-/* $Id$
- *
- * Maurice LeBrun
- * IFS, University of Texas at Austin
- * 18-Jul-1994
- *
- * Contains macro definitions that determine what device drivers are
- * compiled into the PLplot library. On a Unix system, typically the
- * configure script builds plDevs.h from plDevs.h.in. Elsewhere, it's
- * best to hand-configure a plDevs.h file and keep it with the
- * system-specific files.
- *
- * Copyright (C) 2004 Andrew Roach
- * Copyright (C) 2005 Thomas J. Duck
- * Copyright (C) 2006 Andrew Ross
- * Copyright (C) 2006 Alan W. Irwin
- *
- * This file is part of PLplot.
- *
- * PLplot is free software; you can redistribute it and/or modify
- * it under the terms of the GNU Library General Public License as published
- * by the Free Software Foundation; either version 2 of the License, or
- * (at your option) any later version.
- *
- * PLplot is distributed in the hope that it will be useful,
- * but WITHOUT ANY WARRANTY; without even the implied warranty of
- * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
- * GNU Library General Public License for more details.
- *
- * You should have received a copy of the GNU Library General Public License
- * along with PLplot; if not, write to the Free Software
- * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301 USA
- *
- */
+// -*-C-*-
+// $Id$
+//
+// Maurice LeBrun
+// IFS, University of Texas at Austin
+// 18-Jul-1994
+//
+// Contains macro definitions that determine what device drivers are
+// compiled into the PLplot library. On a Unix system, typically the
+// configure script builds plDevs.h from plDevs.h.in. Elsewhere, it's
+// best to hand-configure a plDevs.h file and keep it with the
+// system-specific files.
+//
+// Copyright (C) 2004 Andrew Roach
+// Copyright (C) 2005 Thomas J. Duck
+// Copyright (C) 2006 Andrew Ross
+// Copyright (C) 2006 Alan W. Irwin
+//
+// This file is part of PLplot.
+//
+// PLplot is free software; you can redistribute it and/or modify
+// it under the terms of the GNU Library General Public License as published
+// by the Free Software Foundation; either version 2 of the License, or
+// (at your option) any later version.
+//
+// PLplot is distributed in the hope that it will be useful,
+// but WITHOUT ANY WARRANTY; without even the implied warranty of
+// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
+// GNU Library General Public License for more details.
+//
+// You should have received a copy of the GNU Library General Public License
+// along with PLplot; if not, write to the Free Software
+// Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301 USA
+//
+//
#ifndef __PLDEVS_H__
#define __PLDEVS_H__
@@ -98,4 +98,4 @@
#cmakedefine PLD_extqt
#cmakedefine PLD_memqt
-#endif /* __PLDEVS_H__ */
+#endif // __PLDEVS_H__
Modified: trunk/include/plcore.h
===================================================================
--- trunk/include/plcore.h 2010-10-22 00:17:31 UTC (rev 11268)
+++ trunk/include/plcore.h 2010-10-22 00:25:36 UTC (rev 11269)
@@ -1,28 +1,28 @@
-/* $Id$
- *
- * Contains declarations for core plplot data structures. This file
- * should be included only by plcore.c.
- *
- * Copyright (C) 2004 Andrew Roach
- * Copyright (C) 2005 Thomas J. Duck
- *
- * This file is part of PLplot.
- *
- * PLplot is free software; you can redistribute it and/or modify
- * it under the terms of the GNU Library General Public License as published
- * by the Free Software Foundation; either version 2 of the License, or
- * (at your option) any later version.
- *
- * PLplot is distributed in the hope that it will be useful,
- * but WITHOUT ANY WARRANTY; without even the implied warranty of
- * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
- * GNU Library General Public License for more details.
- *
- * You should have received a copy of the GNU Library General Public License
- * along with PLplot; if not, write to the Free Software
- * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301 USA
- *
- */
+// $Id$
+//
+// Contains declarations for core plplot data structures. This file
+// should be included only by plcore.c.
+//
+// Copyright (C) 2004 Andrew Roach
+// Copyright (C) 2005 Thomas J. Duck
+//
+// This file is part of PLplot.
+//
+// PLplot is free software; you can redistribute it and/or modify
+// it under the terms of the GNU Library General Public License as published
+// by the Free Software Foundation; either version 2 of the License, or
+// (at your option) any later version.
+//
+// PLplot is distributed in the hope that it will be useful,
+// but WITHOUT ANY WARRANTY; without even the implied warranty of
+// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
+// GNU Library General Public License for more details.
+//
+// You should have received a copy of the GNU Library General Public License
+// along with PLplot; if not, write to the Free Software
+// Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301 USA
+//
+//
#ifndef __PLCORE_H__
#define __PLCORE_H__
@@ -48,7 +48,7 @@
#endif
-/* Static function prototypes */
+// Static function prototypes
static char *utf8_to_ucs4( const char *ptr, PLUNICODE *unichar );
static void grline( short *, short *, PLINT );
@@ -67,48 +67,48 @@
static void plLoadDriver( void );
-/* Static variables */
+// Static variables
static PLINT xscl[PL_MAXPOLY], yscl[PL_MAXPOLY];
-static PLINT initfont = 1; /* initial font: extended by default */
+static PLINT initfont = 1; // initial font: extended by default
static PLINT lib_initialized = 0;
-/*--------------------------------------------------------------------------*\
- * Allocate a PLStream data structure (defined in plstrm.h).
- *
- * This struct contains a copy of every variable that is stream dependent.
- * Only the first [index=0] stream is statically allocated; the rest
- * are dynamically allocated when you switch streams (yes, it is legal
- * to only initialize the first element of the array of pointers).
- \*--------------------------------------------------------------------------*/
+//--------------------------------------------------------------------------
+// Allocate a PLStream data structure (defined in plstrm.h).
+//
+// This struct contains a copy of every variable that is stream dependent.
+// Only the first [index=0] stream is statically allocated; the rest
+// are dynamically allocated when you switch streams (yes, it is legal
+// to only initialize the first element of the array of pointers).
+//--------------------------------------------------------------------------
-static PLStream pls0; /* preallocated stream */
-static PLINT ipls; /* current stream number */
+static PLStream pls0; // preallocated stream
+static PLINT ipls; // current stream number
-static PLStream *pls[PL_NSTREAMS] = { &pls0 }; /* Array of stream pointers */
+static PLStream *pls[PL_NSTREAMS] = { &pls0 }; // Array of stream pointers
-/* Current stream pointer. Global, for easier access to state info */
+// Current stream pointer. Global, for easier access to state info
PLDLLIMPEXP_DATA( PLStream ) * plsc = &pls0;
-/* Only now can we include this */
+// Only now can we include this
#include "pldebug.h"
-/*--------------------------------------------------------------------------*\
- * Initialize dispatch table.
- *
- * Each device is selected by the appropriate define, passed in from the
- * makefile. When installing plplot you may wish to exclude devices not
- * present on your system in order to reduce screen clutter.
- *
- * If you hit a <CR> in response to the plinit() prompt, you get the FIRST
- * one active below, so arrange them accordingly for your system (i.e. all
- * the system-specific ones should go first, since they won't appear on
- * most systems.)
- \*--------------------------------------------------------------------------*/
+//--------------------------------------------------------------------------
+// Initialize dispatch table.
+//
+// Each device is selected by the appropriate define, passed in from the
+// makefile. When installing plplot you may wish to exclude devices not
+// present on your system in order to reduce screen clutter.
+//
+// If you hit a <CR> in response to the plinit() prompt, you get the FIRST
+// one active below, so arrange them accordingly for your system (i.e. all
+// the system-specific ones should go first, since they won't appear on
+// most systems.)
+//--------------------------------------------------------------------------
static PLDispatchTable **dispatch_table = 0;
static int npldrivers = 0;
@@ -145,7 +145,7 @@
#ifdef PLD_win3
plD_dispatch_init_win3,
#endif
-#if defined ( _MSC_VER ) && defined ( VGA ) /* graphics for msc */
+#if defined ( _MSC_VER ) && defined ( VGA ) // graphics for msc
plD_dispatch_init_vga,
#endif
#ifdef PLD_bgi
@@ -163,7 +163,7 @@
#if defined ( PLD_bmp ) && !defined ( ENABLE_DYNDRIVERS )
plD_dispatch_init_bmp,
#endif
-#ifdef PLD_emxvga /* graphics for emx+gcc */
+#ifdef PLD_emxvga // graphics for emx+gcc
plD_dispatch_init_vga,
#endif
#if defined ( PLD_xterm ) && !defined ( ENABLE_DYNDRIVERS )
@@ -340,9 +340,9 @@
sizeof ( PLDispatchInit ) ) - 1;
static int npldynamicdevices = 0;
-/*--------------------------------------------------------------------------*\
- * Stuff to support the loadable device drivers.
- \*--------------------------------------------------------------------------*/
+//--------------------------------------------------------------------------
+// Stuff to support the loadable device drivers.
+//--------------------------------------------------------------------------
#ifdef ENABLE_DYNDRIVERS
typedef struct
@@ -366,4 +366,4 @@
static int nloadabledrivers = 0;
-#endif /* __PLCORE_H__ */
+#endif // __PLCORE_H__
Modified: trunk/include/pldebug.h
===================================================================
--- trunk/include/pldebug.h 2010-10-22 00:17:31 UTC (rev 11268)
+++ trunk/include/pldebug.h 2010-10-22 00:25:36 UTC (rev 11269)
@@ -1,25 +1,25 @@
-/* $Id$
- *
- * Copyright (C) 1995 by Maurice J. LeBrun
- *
- * Debugging support for PLplot.
- *
- * This software may be freely copied, modified and redistributed without
- * fee provided that this copyright notice is preserved intact on all
- * copies and modified copies.
- *
- * There is no warranty or other guarantee of fitness of this software.
- * It is provided solely "as is". The author(s) disclaim(s) all
- * responsibility and liability with respect to this software's usage or
- * its effect upon hardware or computer systems.
- */
+// $Id$
+//
+// Copyright (C) 1995 by Maurice J. LeBrun
+//
+// Debugging support for PLplot.
+//
+// This software may be freely copied, modified and redistributed without
+// fee provided that this copyright notice is preserved intact on all
+// copies and modified copies.
+//
+// There is no warranty or other guarantee of fitness of this software.
+// It is provided solely "as is". The author(s) disclaim(s) all
+// responsibility and liability with respect to this software's usage or
+// its effect upon hardware or computer systems.
+//
#ifndef __PLDEBUG_H__
#define __PLDEBUG_H__
#include <stdarg.h>
-/* For the truly desperate debugging task */
+// For the truly desperate debugging task
#ifdef DEBUG_ENTER
#define dbug_enter( a ) \
@@ -30,32 +30,32 @@
#define dbug_enter( a )
#endif
-/* If we're using a debugging malloc, include the header file here */
+// If we're using a debugging malloc, include the header file here
#ifdef DEBUGGING_MALLOC
#include <malloc.h>
#endif
-/*--------------------------------------------------------------------------*\
- * pldebug()
- *
- * Included into every plplot source file to control debugging output. To
- * enable printing of debugging output, you must #define DEBUG before
- * including plplotP.h or specify -DDEBUG in the compile line, for each file
- * that you want to have debug output enabled. When running the program you
- * must in addition specify -debug. This allows debugging output to tailored
- * to many different circumstances but otherwise be fairly unobtrusive.
- *
- * Note, any file that actually uses pldebug() must also define NEED_PLDEBUG
- * before the plplotP.h include. This is to eliminate warnings caused by
- * those files in which this is defined but never referenced. All this could
- * be much nicer if CPP had the abilities of m4, sigh..
- *
- ...
[truncated message content] |