Enhanced NEdit
This is a snapshot of the nedit 5.2 cvs tree that I have added export functionality to. For the moment it can only export to color HTML but color postscript might be added as well.
To download goto the Enhanced NEdit project page
If you want to download the original nedit or find out more information about it, go to http://www.nedit.org
Examples
HTML
<body >
<table cellpadding="0" cellspacing="3" border="0" width="100%" cols="3">
<tr>
<td align="left">
<table width="100%" border="0" cellspacing="0" cellpadding="0" >C
/********************
* exportToHTML
*
* DESCRIPTION
* Exports code to HTML with the syntax highlighting.
*
* RETURNS
* int
*
*/
static void exportToHTML( Widget w, XEvent *event, String *args, Cardinal *nArgs) {
int i, j, response;
int fileLen;
int screenNum = XScreenNumberOfScreen( XtScreen(w));
char **colorTagData;
char **colorTagCloseData;
char lastStyle = -1;
char currentStyle;
char *fileString = NULL;
char *styleString = NULL;
char name[MAXPATHLEN] = "";
FILE *fp = NULL;
XColor color;
WindowInfo *window = WidgetToWindow(w);
Display *display = XtDisplay( w );
Colormap colormap = DefaultColormap( display, screenNum );
windowHighlightData *highlightData;
textDisp *textD = ((TextWidget)window->textArea)->text.textD;
int tabDist = BufGetTabDistance( window->buffer );
/*Is syntaxhighlighting turned on?*/
if( !window->highlightSyntax ) {
DialogF( DF_WARN, window->shell, 1,
"Turn on syntax highlighting before exporting.",
"Dismiss" );
return;
}
response = PromptForHTMLFile( window, "Export to HTML:", name );










