Updated for 1.2.0.7 development
This commit is contained in:
parent
32abbb9470
commit
e3a5c7abeb
159
src/Makefile.am
159
src/Makefile.am
|
@ -1,79 +1,80 @@
|
|||
# these are the headers for your project
|
||||
noinst_HEADERS = *.h
|
||||
|
||||
#########################################################################
|
||||
# APPLICATION SECTION
|
||||
#########################################################################
|
||||
# this is the program that gets installed. it's name is used for all
|
||||
# of the other Makefile.am variables
|
||||
bin_PROGRAMS = xmlcopyeditor
|
||||
bindir = ${prefix}/bin
|
||||
xmlcopyeditordir = ${prefix}/share/xmlcopyeditor
|
||||
pixmapdir = /usr/share/pixmaps
|
||||
applicationsdir = /usr/share/applications
|
||||
|
||||
# the application source, library search path, and link libraries
|
||||
xmlcopyeditor_SOURCES = xmlcopyeditor.cpp associatedialog.cpp casehandler.cpp \
|
||||
contexthandler.cpp globalreplacedialog.cpp housestyle.cpp \
|
||||
housestylereader.cpp myhtmlpane.cpp nocasecompare.cpp readfile.cpp \
|
||||
replace.cpp styledialog.cpp wraplibxml.cpp \
|
||||
wrapregex.cpp wraptempfilename.cpp xmlassociatedtd.cpp xmlassociatexsd.cpp \
|
||||
xmlassociatexsl.cpp xmlctrl.cpp xmldoc.cpp xmlencodinghandler.cpp xmlfilterreader.cpp \
|
||||
xmlpromptgenerator.cpp xmlrulereader.cpp xmlschemalocator.cpp xmlutf8reader.cpp xsllocator.cpp \
|
||||
wrapexpat.cpp mypropertysheet.cpp rule.cpp housestylewriter.cpp myipc.cpp aboutdialog.cpp pathresolver.cpp mynotebook.cpp \
|
||||
insertpanel.cpp xmlwordcount.cpp getword.cpp locationpanel.cpp catalogresolver.cpp getlinuxappdir.cpp \
|
||||
xmlparseschemans.cpp xmlshallowvalidator.cpp wrapxerces.cpp \
|
||||
findreplacepanel.cpp commandpanel.cpp xercescatalogresolver.cpp \
|
||||
binaryfile.cpp xmlencodingspy.cpp wrapaspell.cpp validationthread.cpp \
|
||||
wrapdaisy.cpp exportdialog.cpp mp3album.cpp xmlprodnote.cpp \
|
||||
rulesets png rng xpm templates copying help po \
|
||||
xmlcopyeditor.spec xmlcopyeditor.png custom.xpm \
|
||||
xmlcopyeditor.desktop
|
||||
xmlcopyeditor_LDFLAGS = $(WX_LIBS) \
|
||||
-lexpat -lxslt -lxml2 -lpcre -lxerces-c $(ASPELL_LIBS) $(ENCHANT_LIBS)
|
||||
|
||||
nobase_xmlcopyeditor_DATA = png/*.png \
|
||||
rulesets/*.* \
|
||||
rng/*.rng \
|
||||
rng/*.rnc \
|
||||
rng/exclude/*.rng \
|
||||
rng/modules/*.rng \
|
||||
xpm/*.xpm \
|
||||
templates/*.xml \
|
||||
templates/*.dtd \
|
||||
templates/*.xsl \
|
||||
templates/*.rss \
|
||||
templates/*.html \
|
||||
templates/*.xtm \
|
||||
templates/*.xsd \
|
||||
templates/*.rng \
|
||||
templates/*.lzx \
|
||||
templates/*.xlf \
|
||||
help/*.* help/html/*.* \
|
||||
copying/*.txt copying/boost_shared_ptr/* \
|
||||
copying/Expat/* copying/libxml2/* copying/libxslt/* \
|
||||
copying/PCRE/* copying/Scintilla/* \
|
||||
copying/wxStyledTextCtrl/* \
|
||||
copying/wxStEditor/* \
|
||||
copying/xmlcopyeditor/* \
|
||||
copying/Aspell/* \
|
||||
copying/Apache/LICENSE-2.0 \
|
||||
copying/Apache/LICENSE-2_files/* \
|
||||
po/sk/messages.mo \
|
||||
po/sv/messages.mo \
|
||||
po/fr/messages.mo \
|
||||
po/de/messages.mo \
|
||||
po/ru/messages.mo \
|
||||
po/es/messages.mo \
|
||||
po/zh_CN/messages.mo \
|
||||
po/zh_TW/messages.mo \
|
||||
po/uk_UA/messages.mo \
|
||||
po/uk_UA/messages.mo \
|
||||
po/en_us/messages.po
|
||||
|
||||
pixmap_DATA = xmlcopyeditor.png
|
||||
|
||||
applications_DATA = xmlcopyeditor.desktop
|
||||
|
||||
INCLUDES = -I/usr/include/libxml2 $(ENCHANT_CFLAGS)
|
||||
|
||||
# these are the headers for your project
|
||||
noinst_HEADERS = *.h
|
||||
|
||||
#########################################################################
|
||||
# APPLICATION SECTION
|
||||
#########################################################################
|
||||
# this is the program that gets installed. it's name is used for all
|
||||
# of the other Makefile.am variables
|
||||
bin_PROGRAMS = xmlcopyeditor
|
||||
bindir = ${prefix}/bin
|
||||
xmlcopyeditordir = ${prefix}/share/xmlcopyeditor
|
||||
pixmapdir = /usr/share/pixmaps
|
||||
applicationsdir = /usr/share/applications
|
||||
|
||||
# the application source, library search path, and link libraries
|
||||
xmlcopyeditor_SOURCES = xmlcopyeditor.cpp associatedialog.cpp casehandler.cpp \
|
||||
contexthandler.cpp globalreplacedialog.cpp housestyle.cpp \
|
||||
housestylereader.cpp myhtmlpane.cpp nocasecompare.cpp readfile.cpp \
|
||||
replace.cpp styledialog.cpp wraplibxml.cpp \
|
||||
wrapregex.cpp wraptempfilename.cpp xmlassociatedtd.cpp xmlassociatexsd.cpp \
|
||||
xmlassociatexsl.cpp xmlctrl.cpp xmldoc.cpp xmlencodinghandler.cpp xmlfilterreader.cpp \
|
||||
xmlpromptgenerator.cpp xmlrulereader.cpp xmlschemalocator.cpp xmlutf8reader.cpp xsllocator.cpp \
|
||||
wrapexpat.cpp mypropertysheet.cpp rule.cpp housestylewriter.cpp myipc.cpp aboutdialog.cpp pathresolver.cpp mynotebook.cpp \
|
||||
insertpanel.cpp xmlwordcount.cpp getword.cpp locationpanel.cpp catalogresolver.cpp getlinuxappdir.cpp \
|
||||
xmlparseschemans.cpp xmlshallowvalidator.cpp wrapxerces.cpp \
|
||||
findreplacepanel.cpp commandpanel.cpp xercescatalogresolver.cpp \
|
||||
binaryfile.cpp xmlencodingspy.cpp wrapaspell.cpp validationthread.cpp \
|
||||
wrapdaisy.cpp exportdialog.cpp mp3album.cpp xmlprodnote.cpp \
|
||||
xmlsuppressprodnote.cpp xmlcopyimg.cpp \
|
||||
rulesets png rng xpm templates copying help po \
|
||||
xmlcopyeditor.spec xmlcopyeditor.png custom.xpm \
|
||||
xmlcopyeditor.desktop
|
||||
xmlcopyeditor_LDFLAGS = $(WX_LIBS) \
|
||||
-lexpat -lxslt -lxml2 -lpcre -lxerces-c $(ASPELL_LIBS) $(ENCHANT_LIBS)
|
||||
|
||||
nobase_xmlcopyeditor_DATA = png/*.png \
|
||||
rulesets/*.* \
|
||||
rng/*.rng \
|
||||
rng/*.rnc \
|
||||
rng/exclude/*.rng \
|
||||
rng/modules/*.rng \
|
||||
xpm/*.xpm \
|
||||
templates/*.xml \
|
||||
templates/*.dtd \
|
||||
templates/*.xsl \
|
||||
templates/*.rss \
|
||||
templates/*.html \
|
||||
templates/*.xtm \
|
||||
templates/*.xsd \
|
||||
templates/*.rng \
|
||||
templates/*.lzx \
|
||||
templates/*.xlf \
|
||||
help/*.* help/html/*.* \
|
||||
copying/*.txt copying/boost_shared_ptr/* \
|
||||
copying/Expat/* copying/libxml2/* copying/libxslt/* \
|
||||
copying/PCRE/* copying/Scintilla/* \
|
||||
copying/wxStyledTextCtrl/* \
|
||||
copying/wxStEditor/* \
|
||||
copying/xmlcopyeditor/* \
|
||||
copying/Aspell/* \
|
||||
copying/Apache/LICENSE-2.0 \
|
||||
copying/Apache/LICENSE-2_files/* \
|
||||
po/sk/messages.mo \
|
||||
po/sv/messages.mo \
|
||||
po/fr/messages.mo \
|
||||
po/de/messages.mo \
|
||||
po/ru/messages.mo \
|
||||
po/es/messages.mo \
|
||||
po/zh_CN/messages.mo \
|
||||
po/zh_TW/messages.mo \
|
||||
po/uk_UA/messages.mo \
|
||||
po/ca/messages.mo \
|
||||
po/en_us/messages.po
|
||||
|
||||
pixmap_DATA = xmlcopyeditor.png
|
||||
|
||||
applications_DATA = xmlcopyeditor.desktop
|
||||
|
||||
INCLUDES = -I/usr/include/libxml2 $(ENCHANT_CFLAGS)
|
||||
|
||||
|
|
1445
src/Makefile.in
1445
src/Makefile.in
File diff suppressed because it is too large
Load Diff
|
@ -30,7 +30,7 @@ BinaryFile::BinaryFile ( const char *fname ) : m_data ( 0 ), m_dataLen ( 0 )
|
|||
pFile = fopen ( fname, "rb" );
|
||||
if ( pFile == NULL )
|
||||
{
|
||||
throw;
|
||||
return;
|
||||
}
|
||||
|
||||
// obtain file size
|
||||
|
@ -44,7 +44,7 @@ BinaryFile::BinaryFile ( const char *fname ) : m_data ( 0 ), m_dataLen ( 0 )
|
|||
buffer = ( char* ) malloc ( sizeof ( char ) *lSize );
|
||||
if ( buffer == NULL )
|
||||
{
|
||||
throw;
|
||||
return;
|
||||
}
|
||||
|
||||
// copy the file into the buffer:
|
||||
|
@ -52,7 +52,7 @@ BinaryFile::BinaryFile ( const char *fname ) : m_data ( 0 ), m_dataLen ( 0 )
|
|||
if ( result != lSize )
|
||||
{
|
||||
if ( !feof ( pFile ) )
|
||||
throw;
|
||||
return;
|
||||
}
|
||||
|
||||
/* the whole file is now loaded in the memory buffer. */
|
||||
|
|
|
@ -1,11 +1,11 @@
|
|||
XML Copy Editor
|
||||
|
||||
Copyright (c) 2005-2007 Gerald Schmidt
|
||||
|
||||
This program is free software; you can redistribute it and/or modify it under the terms of the GNU General Public License as published by the Free Software Foundation; either version 2 of the License, or (at your option) any later version.
|
||||
|
||||
This program 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 General Public License for more details.
|
||||
|
||||
You should have received a copy of the GNU General Public License along with this program; if not, write to the Free Software Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA
|
||||
XML Copy Editor
|
||||
|
||||
Copyright (c) 2005-2007 Gerald Schmidt
|
||||
|
||||
This program is free software; you can redistribute it and/or modify it under the terms of the GNU General Public License as published by the Free Software Foundation; either version 2 of the License, or (at your option) any later version.
|
||||
|
||||
This program 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 General Public License for more details.
|
||||
|
||||
You should have received a copy of the GNU General Public License along with this program; if not, write to the Free Software Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA
|
||||
|
|
|
@ -134,7 +134,7 @@ ExportDialog::ExportDialog (
|
|||
wxID_ANY,
|
||||
_ ( "Download DAISY extension" ),
|
||||
#ifdef __WXMSW__
|
||||
_T ( "https://sourceforge.net/projects/xml-copy-editor/files/xmlcopyeditor-daisy/xmlcopyeditor-daisy-1.0.exe/download" )
|
||||
_T ( "https://sourceforge.net/projects/xml-copy-editor/files/xmlcopyeditor-daisy/xmlcopyeditor-daisy-1.0.1.exe/download" )
|
||||
#else
|
||||
_T ( "http://xml-copy-editor.sourceforge.net" )
|
||||
#endif
|
||||
|
|
|
@ -255,7 +255,7 @@ void FindReplacePanel::setReplaceVisible ( bool b )
|
|||
|
||||
void FindReplacePanel::flagNotFound ( bool b )
|
||||
{
|
||||
if ( notFoundSet && b || !notFoundSet && !b )
|
||||
if ( ( notFoundSet && b ) || ( !notFoundSet && !b ) )
|
||||
return;
|
||||
|
||||
notFoundSet = b;
|
||||
|
|
Binary file not shown.
|
@ -2,7 +2,7 @@
|
|||
Binary Index=No
|
||||
Compatibility=1.1 or later
|
||||
Compiled file=xmlcopyeditor.chm
|
||||
Contents file=Table of Contents.hhc
|
||||
Contents file=Table_of_Contents.hhc
|
||||
Default Font=@Arial Unicode MS,8,0
|
||||
Default topic=html\features.html
|
||||
Display compile progress=No
|
||||
|
|
File diff suppressed because it is too large
Load Diff
|
@ -17,6 +17,7 @@
|
|||
* Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA
|
||||
*/
|
||||
|
||||
#include <cstdio>
|
||||
#include <cstring>
|
||||
#include "replace.h"
|
||||
|
||||
|
|
|
@ -20,6 +20,8 @@
|
|||
#ifndef STRINGSET_H
|
||||
#define STRINGSET_H
|
||||
|
||||
#include <stdint.h>
|
||||
#include <cstdio>
|
||||
#include <string>
|
||||
#include <stdexcept>
|
||||
#include <cmath>
|
||||
|
|
|
@ -137,7 +137,6 @@ StyleDialog::StyleDialog (
|
|||
ruleSetCombo->GetSize ( &width, &height );
|
||||
wxSize buttonSize ( 100, height );
|
||||
|
||||
|
||||
filterCombo = new wxComboBox (
|
||||
this,
|
||||
ID_STYLE_COMBO_FILTER,
|
||||
|
@ -329,6 +328,7 @@ StyleDialog::StyleDialog (
|
|||
if ( !ruleFile.empty() )
|
||||
{
|
||||
ruleFile.Replace ( _T ( ".xml" ), _T ( "" ) );
|
||||
ruleFile.Replace ( _T ( "_" ), _T ( " " ) );
|
||||
ruleSetCombo->Append ( wxFileNameFromPath ( ruleFile ) );
|
||||
for ( ;; )
|
||||
{
|
||||
|
@ -336,6 +336,7 @@ StyleDialog::StyleDialog (
|
|||
if ( ruleFile.empty() )
|
||||
break;
|
||||
ruleFile.Replace ( _T ( ".xml" ), _T ( "" ) );
|
||||
ruleFile.Replace ( _T ( "_" ), _T ( " " ) );
|
||||
ruleSetCombo->Append ( wxFileNameFromPath ( ruleFile ) );
|
||||
}
|
||||
}
|
||||
|
@ -455,6 +456,7 @@ void StyleDialog::OnReport ( wxCommandEvent& event )
|
|||
// reconstitute short filenames
|
||||
wxString ruleSet, filter;
|
||||
ruleSet = ruleSetPreset + _T ( ".xml" );
|
||||
ruleSet.Replace ( _(" "), _T("_") );
|
||||
filter = filterPreset + _T ( ".xml" );
|
||||
|
||||
std::string ruleSetDirectoryUtf8,
|
||||
|
|
|
@ -18,6 +18,7 @@
|
|||
*/
|
||||
|
||||
#include <iostream>
|
||||
#include <cstdio>
|
||||
#include <stdexcept>
|
||||
#include "wrapaspell.h"
|
||||
#ifdef USE_ENCHANT
|
||||
|
|
|
@ -11,7 +11,6 @@
|
|||
#include "xmlcopyimg.h"
|
||||
#include "binaryfile.h"
|
||||
#include "replace.h"
|
||||
#include "playlistrenamer.h"
|
||||
#include "mp3album.h"
|
||||
|
||||
#ifdef __WXMSW__
|
||||
|
@ -109,6 +108,9 @@ bool WrapDaisy::run (
|
|||
{
|
||||
// #1: convert to canonical XHTML
|
||||
pd->ProcessPendingEvents();
|
||||
while (wxTheApp->Pending())
|
||||
wxTheApp->Dispatch();
|
||||
|
||||
if ( !pd->Update ( 10, _T("Preparing canonical XHTML...") ) )
|
||||
{
|
||||
error = _T( "Cancelled" );
|
||||
|
@ -136,12 +138,10 @@ bool WrapDaisy::run (
|
|||
}
|
||||
else // no stylesheet
|
||||
{
|
||||
try {
|
||||
BinaryFile bf( stdFileIn.c_str() );
|
||||
BinaryFile bf( stdFileIn.c_str() );
|
||||
if ( !bf.getData() )
|
||||
{
|
||||
output.append ( bf.getData(), bf.getDataLen() );
|
||||
}
|
||||
catch ( ... )
|
||||
{
|
||||
error = _( "Cannot read [b]" ) + fileIn + ( _("[/b]") );
|
||||
return false;
|
||||
}
|
||||
|
@ -150,6 +150,8 @@ bool WrapDaisy::run (
|
|||
if ( suppressOptional )
|
||||
{
|
||||
pd->ProcessPendingEvents();
|
||||
while (wxTheApp->Pending())
|
||||
wxTheApp->Dispatch();
|
||||
if ( !pd->Update ( 15, _("Suppressing optional production notes...") ) )
|
||||
{
|
||||
error = _ ( "Cancelled" );
|
||||
|
@ -171,6 +173,8 @@ bool WrapDaisy::run (
|
|||
{
|
||||
// #1.5: apply quiet setting if req'd
|
||||
pd->ProcessPendingEvents();
|
||||
while (wxTheApp->Pending())
|
||||
wxTheApp->Dispatch();
|
||||
if ( !pd->Update ( 20, _("De-emphasizing production notes...") ) )
|
||||
{
|
||||
error = _ ( "Cancelled" );
|
||||
|
@ -238,6 +242,9 @@ bool WrapDaisy::run (
|
|||
|
||||
// copy images
|
||||
pd->ProcessPendingEvents();
|
||||
while (wxTheApp->Pending())
|
||||
wxTheApp->Dispatch();
|
||||
|
||||
if ( !pd->Update ( 25, _("Copying images and audio files...") ) )
|
||||
{
|
||||
error = _ ( "Cancelled" );
|
||||
|
@ -270,6 +277,9 @@ bool WrapDaisy::run (
|
|||
|
||||
// #2: convert to DTBook
|
||||
pd->ProcessPendingEvents();
|
||||
while (wxTheApp->Pending())
|
||||
wxTheApp->Dispatch();
|
||||
|
||||
if ( !pd->Update ( 40, _T("Preparing DTBook...") ) )
|
||||
{
|
||||
error = _T ( "Cancelled" );
|
||||
|
@ -320,6 +330,9 @@ bool WrapDaisy::run (
|
|||
|
||||
// #2.5: create EPUB version
|
||||
pd->ProcessPendingEvents();
|
||||
while (wxTheApp->Pending())
|
||||
wxTheApp->Dispatch();
|
||||
|
||||
if ( !pd->Update ( 50, _T("Preparing ePub...") ) )
|
||||
{
|
||||
error = _T ( "Cancelled" );
|
||||
|
@ -371,6 +384,9 @@ bool WrapDaisy::run (
|
|||
|
||||
// #2.9: convert to RTF
|
||||
pd->ProcessPendingEvents();
|
||||
while (wxTheApp->Pending())
|
||||
wxTheApp->Dispatch();
|
||||
|
||||
if ( !pd->Update ( 60, _T("Preparing RTF...") ) )
|
||||
{
|
||||
error = _T ( "Cancelled" );
|
||||
|
@ -425,7 +441,10 @@ bool WrapDaisy::run (
|
|||
// #2.9.5: convert to binary Word
|
||||
// (Win only; otherwise create copy with *.doc extension)
|
||||
|
||||
pd->ProcessPendingEvents();
|
||||
pd->ProcessPendingEvents();
|
||||
while (wxTheApp->Pending())
|
||||
wxTheApp->Dispatch();
|
||||
|
||||
if ( !pd->Update ( 60, _T("Preparing Word document...") ) )
|
||||
{
|
||||
error = _T ( "Cancelled" );
|
||||
|
@ -468,6 +487,9 @@ bool WrapDaisy::run (
|
|||
|
||||
// #3: convert to full DAISY book
|
||||
pd->ProcessPendingEvents();
|
||||
while (wxTheApp->Pending())
|
||||
wxTheApp->Dispatch();
|
||||
|
||||
if ( !pd->Update ( 70, _T("Preparing DAISY books...") ) )
|
||||
{
|
||||
error = _T ( "Cancelled" );
|
||||
|
@ -521,6 +543,9 @@ bool WrapDaisy::run (
|
|||
|
||||
// #4: create MP3 album
|
||||
pd->ProcessPendingEvents();
|
||||
while (wxTheApp->Pending())
|
||||
wxTheApp->Dispatch();
|
||||
|
||||
if ( !pd->Update ( 80, _T("Preparing MP3 album...") ) )
|
||||
{
|
||||
error = _T ( "Cancelled" );
|
||||
|
@ -595,6 +620,9 @@ bool WrapDaisy::run (
|
|||
|
||||
|
||||
pd->ProcessPendingEvents();
|
||||
while (wxTheApp->Pending())
|
||||
wxTheApp->Dispatch();
|
||||
|
||||
if ( !pd->Update ( 90, _T("Updating playlists...") ) )
|
||||
{
|
||||
error = _T ( "Cancelled" );
|
||||
|
@ -621,11 +649,8 @@ bool WrapDaisy::run (
|
|||
auto_ptr<Mp3Album> ma ( new Mp3Album() );
|
||||
|
||||
BinaryFile *binaryfile;
|
||||
try
|
||||
{
|
||||
binaryfile = new BinaryFile ( file.c_str() );
|
||||
}
|
||||
catch ( ... )
|
||||
binaryfile = new BinaryFile ( file.c_str() );
|
||||
if ( !binaryfile->getData() )
|
||||
{
|
||||
error.Printf ( _ ( "Cannot open %s" ), file.c_str() );
|
||||
return false;
|
||||
|
|
|
@ -17,6 +17,7 @@
|
|||
* Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA
|
||||
*/
|
||||
|
||||
#include <cstdio>
|
||||
#include <string>
|
||||
#include <vector>
|
||||
#include <stdexcept>
|
||||
|
|
|
@ -20,6 +20,7 @@
|
|||
#ifndef XML_ASSOCIATE_XSD_H
|
||||
#define XML_ASSOCIATE_XSD_H
|
||||
|
||||
#include <cstdio>
|
||||
#include <vector>
|
||||
#include <expat.h>
|
||||
#include <string>
|
||||
|
|
|
@ -20,6 +20,7 @@
|
|||
#ifndef XML_ASSOCIATE_XSL_H
|
||||
#define XML_ASSOCIATE_XSL_H
|
||||
|
||||
#include <cstdio>
|
||||
#include <vector>
|
||||
#include <expat.h>
|
||||
#include <string>
|
||||
|
|
|
@ -1242,7 +1242,7 @@ void MyFrame::OnAbout ( wxCommandEvent& WXUNUSED ( event ) )
|
|||
info.AddTranslator ( _ ( "Siarhei Kuchuk (Russian) <Cuchuk dot Sergey at gmail dot com>" ) );
|
||||
info.AddTranslator ( _ ( "Marcos Pérez González (Spanish) <marcos_pg at yahoo dot com>" ) );
|
||||
info.AddTranslator ( _ ( "Rob Elemans (Dutch) <relemans at gmail dot com>" ) );
|
||||
info.AddTranslator ( _ ( "Robert Falco Miramontes <rfalco at acett dot org>" ) );
|
||||
info.AddTranslator ( _ ( "Robert Falc\xf3 Miramontes <rfalco at acett dot org>" ) );
|
||||
info.SetLicense ( ABOUT_LICENSE );
|
||||
info.SetDescription ( description );
|
||||
wxAboutBox ( info );
|
||||
|
@ -2727,6 +2727,7 @@ void MyFrame::OnNew ( wxCommandEvent& WXUNUSED ( event ) )
|
|||
templateFile = wxFindNextFile();
|
||||
if ( templateFile.empty() )
|
||||
break;
|
||||
templateFile.Replace ( _T("_"), _T(" ") );
|
||||
fn.Assign ( templateFile );
|
||||
name = fn.GetName();
|
||||
extension = fn.GetExt();
|
||||
|
@ -2765,6 +2766,7 @@ void MyFrame::OnNew ( wxCommandEvent& WXUNUSED ( event ) )
|
|||
|
||||
typeSelection.Replace ( _T ( " (*" ), wxEmptyString );
|
||||
typeSelection.Replace ( _T ( ")" ), wxEmptyString );
|
||||
typeSelection.Replace ( _T ( " " ), _T ( "_" ) );
|
||||
templateFile = templateDir + typeSelection;
|
||||
std::string templateFileLocal, buffer;
|
||||
templateFileLocal = templateFile.mb_str ( wxConvLocal );
|
||||
|
@ -2926,25 +2928,8 @@ bool MyFrame::openFile ( wxString& fileName, bool largeFile )
|
|||
//wxMemoryMappedFile *memorymap = NULL;
|
||||
BinaryFile *binaryfile = NULL;
|
||||
|
||||
try
|
||||
{
|
||||
binaryfile = new BinaryFile ( ( const char * ) fileName.mb_str ( wxConvLocal ) );
|
||||
/*
|
||||
memorymap = new wxMemoryMappedFile(
|
||||
fileName,
|
||||
true, // readOnly
|
||||
true // fread
|
||||
);
|
||||
*/
|
||||
|
||||
}
|
||||
/*
|
||||
catch (wxMemoryMappedFileEmptyException&)
|
||||
{
|
||||
fileEmpty = true;
|
||||
}
|
||||
*/
|
||||
catch ( ... )
|
||||
binaryfile = new BinaryFile ( ( const char * ) fileName.mb_str ( wxConvLocal ) );
|
||||
if ( !binaryfile->getData() )
|
||||
{
|
||||
wxString message;
|
||||
message.Printf ( _ ( "Cannot open %s" ), fileName.c_str() );
|
||||
|
@ -2952,6 +2937,20 @@ bool MyFrame::openFile ( wxString& fileName, bool largeFile )
|
|||
statusProgress ( wxEmptyString );
|
||||
return false;
|
||||
}
|
||||
/*
|
||||
memorymap = new wxMemoryMappedFile(
|
||||
fileName,
|
||||
true, // readOnly
|
||||
true // fread
|
||||
);
|
||||
*/
|
||||
|
||||
/*
|
||||
catch (wxMemoryMappedFileEmptyException&)
|
||||
{
|
||||
fileEmpty = true;
|
||||
}
|
||||
*/
|
||||
|
||||
bool isUtf8 = false;
|
||||
|
||||
|
@ -5369,9 +5368,11 @@ void MyFrame::updateFileMenu ( bool deleteExisting )
|
|||
wxMenuItem *saveAsItem =
|
||||
new wxMenuItem ( NULL, wxID_SAVEAS, _ ( "S&ave As...\tF12" ), _ ( "Save As..." ) );
|
||||
saveAsItem->SetBitmap ( wxNullBitmap );
|
||||
#ifdef __WXMSW__
|
||||
wxMenuItem *exportItem =
|
||||
new wxMenuItem ( NULL, ID_EXPORT, _ ( "&DAISY Export..." ), _ ( "DAISY Export..." ) );
|
||||
exportItem->SetBitmap ( wxNullBitmap );
|
||||
#endif
|
||||
wxMenuItem *reloadItem =
|
||||
new wxMenuItem ( NULL, ID_RELOAD, _ ( "&Reload" ), _ ( "Reload" ) );
|
||||
reloadItem->SetBitmap ( wxNullBitmap );
|
||||
|
@ -5415,9 +5416,9 @@ void MyFrame::updateFileMenu ( bool deleteExisting )
|
|||
fileMenu->Append ( printSetupItem );
|
||||
fileMenu->Append ( printPreviewItem );
|
||||
fileMenu->Append ( printItem );
|
||||
#ifdef __WXMSW__
|
||||
fileMenu->AppendSeparator();
|
||||
fileMenu->Append ( exportItem );
|
||||
#ifdef __WXMSW__
|
||||
fileMenu->Append ( importMSWordItem );
|
||||
fileMenu->Append ( exportMSWordItem );
|
||||
#endif
|
||||
|
|
|
@ -1,10 +1,10 @@
|
|||
[Desktop Entry]
|
||||
Type=Application
|
||||
Name=XML Copy Editor
|
||||
GenericName=XML Editor
|
||||
Comment=Edit XML documents
|
||||
Exec=xmlcopyeditor %U
|
||||
Icon=xmlcopyeditor.png
|
||||
Terminal=false
|
||||
MimeType=text/xml;
|
||||
Categories=Application;Development;TextEditor;
|
||||
[Desktop Entry]
|
||||
Type=Application
|
||||
Name=XML Copy Editor
|
||||
GenericName=XML Editor
|
||||
Comment=Edit XML documents
|
||||
Exec=xmlcopyeditor %U
|
||||
Icon=xmlcopyeditor.png
|
||||
Terminal=false
|
||||
MimeType=text/xml;
|
||||
Categories=Application;Development;TextEditor;
|
||||
|
|
|
@ -1,40 +1,40 @@
|
|||
%define name xmlcopyeditor
|
||||
%define version 1.1.0.6
|
||||
%define release 1
|
||||
%define author Gerald Schmidt <gnschmidt@users.sourceforge.net>
|
||||
%define prefix /usr/local
|
||||
|
||||
Name: %{name}
|
||||
Version: %{version}
|
||||
Release: %{release}
|
||||
Prefix: %{prefix}
|
||||
Packager: %{author}
|
||||
Source0: %{name}-%{version}.tar.gz
|
||||
Group: Applications/Editors
|
||||
License: GPL
|
||||
BuildRoot: %{_tmppath}/%{name}-%{version}-%{release}-root
|
||||
URL: http://xml-copy-editor.sourceforge.net
|
||||
Vendor: XML Copy Editor Project
|
||||
Summary: XML editor
|
||||
|
||||
%description
|
||||
XML Copy Editor is a fast, free, validating XML editor.
|
||||
%prep
|
||||
%setup -q
|
||||
|
||||
%build
|
||||
./configure --with-wx-config="wx-config --unicode" --datadir="%{prefix}/share"
|
||||
make
|
||||
strip src/xmlcopyeditor
|
||||
rm -rf $RPM_BUILD_ROOT
|
||||
make DESTDIR=$RPM_BUILD_ROOT install
|
||||
|
||||
%clean
|
||||
rm -rf $RPM_BUILD_ROOT
|
||||
|
||||
%files
|
||||
%defattr(-,root,root)
|
||||
%{prefix}/bin/xmlcopyeditor
|
||||
%{prefix}/share/xmlcopyeditor/*
|
||||
/usr/share/applications/xmlcopyeditor.desktop
|
||||
/usr/share/pixmaps/xmlcopyeditor.png
|
||||
%define name xmlcopyeditor
|
||||
%define version 1.1.0.6
|
||||
%define release 1
|
||||
%define author Gerald Schmidt <gnschmidt@users.sourceforge.net>
|
||||
%define prefix /usr/local
|
||||
|
||||
Name: %{name}
|
||||
Version: %{version}
|
||||
Release: %{release}
|
||||
Prefix: %{prefix}
|
||||
Packager: %{author}
|
||||
Source0: %{name}-%{version}.tar.gz
|
||||
Group: Applications/Editors
|
||||
License: GPL
|
||||
BuildRoot: %{_tmppath}/%{name}-%{version}-%{release}-root
|
||||
URL: http://xml-copy-editor.sourceforge.net
|
||||
Vendor: XML Copy Editor Project
|
||||
Summary: XML editor
|
||||
|
||||
%description
|
||||
XML Copy Editor is a fast, free, validating XML editor.
|
||||
%prep
|
||||
%setup -q
|
||||
|
||||
%build
|
||||
./configure --with-wx-config="wx-config --unicode" --datadir="%{prefix}/share"
|
||||
make
|
||||
strip src/xmlcopyeditor
|
||||
rm -rf $RPM_BUILD_ROOT
|
||||
make DESTDIR=$RPM_BUILD_ROOT install
|
||||
|
||||
%clean
|
||||
rm -rf $RPM_BUILD_ROOT
|
||||
|
||||
%files
|
||||
%defattr(-,root,root)
|
||||
%{prefix}/bin/xmlcopyeditor
|
||||
%{prefix}/share/xmlcopyeditor/*
|
||||
/usr/share/applications/xmlcopyeditor.desktop
|
||||
/usr/share/pixmaps/xmlcopyeditor.png
|
||||
|
|
|
@ -25,7 +25,7 @@
|
|||
|
||||
#endif
|
||||
#define ABOUT_COPYRIGHT _("Copyright © 2005-2009 Gerald Schmidt <gnschmidt@users.sourceforge.net>")
|
||||
#define ABOUT_DESCRIPTION _("\nXML Copy Editor is free software released under the GNU\nGeneral Public License.\n\nMany thanks are due to Tim van Niekerk, Matt Smigielski,\nDavid Scholl, Jan Merka, Marcus Bingenheimer, Roberto\nRosselli Del Turco, Ken Zalewski, C.J. Meidlinger,\nThomas Zajic, Viliam Búr, David Håsäther, François\nBadier, Thomas Wenzel, Roger Sperberg, SHiNE CsyFeK,\nHSU PICHAN, YANG SHUFUN, CHENG PAULIAN,\nCHUANG KUO-PING, Justin Dearing, Serhij Dubyk,\nAntonio Angelo, Jose Luis Rivero, Siarhei Kuchuk,\nIan Abbott, Kev James, Marcos Pérez González, Anh\nTrinh, Rob Elemans and Robert Falco Miramontes.")
|
||||
#define ABOUT_DESCRIPTION _("\nXML Copy Editor is free software released under the GNU\nGeneral Public License.\n\nMany thanks are due to Tim van Niekerk, Matt Smigielski,\nDavid Scholl, Jan Merka, Marcus Bingenheimer, Roberto\nRosselli Del Turco, Ken Zalewski, C.J. Meidlinger,\nThomas Zajic, Viliam Búr, David Håsäther, François\nBadier, Thomas Wenzel, Roger Sperberg, SHiNE CsyFeK,\nHSU PICHAN, YANG SHUFUN, CHENG PAULIAN,\nCHUANG KUO-PING, Justin Dearing, Serhij Dubyk,\nAntonio Angelo, Jose Luis Rivero, Siarhei Kuchuk,\nIan Abbott, Kev James, Marcos Pérez González, Anh\nTrinh, Rob Elemans and Robert Falc\xf3 Miramontes.")
|
||||
#define ABOUT_LICENSE _T(\
|
||||
"This program is free software; you can redistribute it\n"\
|
||||
"and/or modify it under the terms of the GNU General Public\n"\
|
||||
|
|
|
@ -135,6 +135,7 @@ void XMLCALL XmlCopyImg::start ( void *data,
|
|||
{
|
||||
wxString cmd;
|
||||
cmd += IMAGEMAGICK_CONVERT_PATH;
|
||||
cmd += _T(" -resize 720x1440>");
|
||||
cmd += _T(" \"");
|
||||
cmd += wideFile;
|
||||
cmd += _T("\" \"");
|
||||
|
@ -156,7 +157,7 @@ void XMLCALL XmlCopyImg::start ( void *data,
|
|||
} // img + src
|
||||
else if ( !strcmp ( el, "a" ) &&
|
||||
!strcmp (*attr, "href") &&
|
||||
strstr ( value.c_str(), ".mp3" ) || strstr ( value.c_str(), ".pdf" ) )
|
||||
( strstr ( value.c_str(), ".mp3" ) || strstr ( value.c_str(), ".pdf" ) ) )
|
||||
{
|
||||
wideFile = wxString ( value.c_str(), wxConvUTF8, value.size() );
|
||||
wxFileName fn ( wideFile );
|
||||
|
|
|
@ -20,6 +20,7 @@
|
|||
#ifndef XML_PRODNOTE_H
|
||||
#define XML_PRODNOTE_H
|
||||
|
||||
#include <cstdio>
|
||||
#include <vector>
|
||||
#include <expat.h>
|
||||
#include <string>
|
||||
|
|
|
@ -31,7 +31,9 @@
|
|||
#include "catalogresolver.h"
|
||||
|
||||
// Xerces-C req'd for Schema parsing
|
||||
#ifdef __WXMSW__
|
||||
#define XERCES_TMPLSINC
|
||||
#endif
|
||||
|
||||
#include <xercesc/util/NameIdPool.hpp>
|
||||
#include <xercesc/util/PlatformUtils.hpp>
|
||||
|
|
|
@ -1,6 +1,7 @@
|
|||
#ifndef XML_SUPPRESS_PRODNOTE_H
|
||||
#define XML_SUPPRESS_PRODNOTE_H
|
||||
|
||||
#include <cstdio>
|
||||
#include <vector>
|
||||
#include <expat.h>
|
||||
#include <string>
|
||||
|
|
|
@ -17,6 +17,7 @@
|
|||
* Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA
|
||||
*/
|
||||
|
||||
#include <cstdio>
|
||||
#include <string>
|
||||
#include <vector>
|
||||
#include <stdexcept>
|
||||
|
|
|
@ -1,5 +1,10 @@
|
|||
/* XPM */
|
||||
#ifdef __WXMSW__
|
||||
static char * appicon_xpm[] = {
|
||||
#else
|
||||
static const char * appicon_xpm[] = {
|
||||
#endif
|
||||
|
||||
"16 16 238 2",
|
||||
" c #742719",
|
||||
". c #9A3320",
|
||||
|
|
|
@ -46,7 +46,11 @@ void XMLCALL XslLocator::processingInstructionHandler (
|
|||
return;
|
||||
|
||||
char *value, *iterator;
|
||||
#ifdef __WXMSW__
|
||||
value = strstr ( ( const char * ) data, "href=" );
|
||||
#else
|
||||
value = ( char *) strstr ( data, "href=" );
|
||||
#endif
|
||||
if ( !value || strlen ( value ) < 7 )
|
||||
return;
|
||||
value += 6;
|
||||
|
|
Loading…
Reference in New Issue