summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorFridrich Štrba <fridrich.strba@bluewin.ch>2012-06-14 15:48:14 +0200
committerFridrich Štrba <fridrich.strba@bluewin.ch>2012-06-14 16:10:34 +0200
commit77251b4d7a15c16afca15a64dbe74e1d7aee98e7 (patch)
treea944e36b33cdff08a808526be5e354d221ae0b84
parentd5d3c8d24af2802ed1ac31ccee9e83e1db08b0b9 (diff)
Cleanup of the skeleton
-rw-r--r--configure.ac16
-rw-r--r--libpgplus-0.0.pc.in4
-rw-r--r--libpgplus.spec.in (renamed from libmspub.spec.in)2
-rw-r--r--src/conv/raw/.gitignore4
-rw-r--r--src/conv/raw/Makefile.am10
-rw-r--r--src/conv/raw/ppp2raw.cpp2
-rw-r--r--src/conv/svg/.gitignore8
-rw-r--r--src/conv/svg/Makefile.am10
-rw-r--r--src/conv/svg/ppp2xhtml.cpp2
-rw-r--r--src/lib/.gitignore1
-rw-r--r--src/lib/PGPLUSCollector.cpp (renamed from src/lib/MSPUBCollector.cpp)0
-rw-r--r--src/lib/PGPLUSCollector.h (renamed from src/lib/MSPUBCollector.h)0
-rw-r--r--src/lib/PGPLUSDocument.cpp (renamed from src/lib/MSPUBDocument.cpp)22
-rw-r--r--src/lib/PGPLUSDocument.h (renamed from src/lib/MSPUBDocument.h)0
-rw-r--r--src/lib/PGPLUSParser.cpp (renamed from src/lib/MSPUBParser.cpp)37
-rw-r--r--src/lib/PGPLUSParser.h (renamed from src/lib/MSPUBParser.h)0
-rw-r--r--src/lib/PGPLUSSVGGenerator.cpp (renamed from src/lib/MSPUBSVGGenerator.cpp)0
-rw-r--r--src/lib/PGPLUSSVGGenerator.h (renamed from src/lib/MSPUBSVGGenerator.h)0
-rw-r--r--src/lib/PGPLUSStringVector.cpp (renamed from src/lib/MSPUBStringVector.cpp)0
-rw-r--r--src/lib/PGPLUSStringVector.h (renamed from src/lib/MSPUBStringVector.h)0
-rw-r--r--src/lib/libpgplus.h (renamed from src/lib/libmspub.h)0
-rw-r--r--src/lib/libpgplus.rc.in (renamed from src/lib/libmspub.rc.in)0
-rw-r--r--src/lib/libpgplus_utils.cpp (renamed from src/lib/libmspub_utils.cpp)0
-rw-r--r--src/lib/libpgplus_utils.h (renamed from src/lib/libmspub_utils.h)0
-rw-r--r--src/lib/makefile.mk5
25 files changed, 38 insertions, 85 deletions
diff --git a/configure.ac b/configure.ac
index fb5f2f3..9a79dd1 100644
--- a/configure.ac
+++ b/configure.ac
@@ -66,20 +66,20 @@ AS_CASE([$host],
[*-*-mingw*], [
native_win32=yes
LIBPGPLUS_WIN32_RESOURCE=libpgplus-win32res.lo
- PUB2RAW_WIN32_RESOURCE=pub2raw-win32res.lo
- PUB2XHTML_WIN32_RESOURCE=pub2xhtml-win32res.lo
+ PPP2RAW_WIN32_RESOURCE=ppp2raw-win32res.lo
+ PPP2XHTML_WIN32_RESOURCE=ppp2xhtml-win32res.lo
], [
native_win32=no
LIBPGPLUS_WIN32_RESOURCE=
- PUB2RAW_WIN32_RESOURCE=
- PUB2XHTML_WIN32_RESOURCE=
+ PPP2RAW_WIN32_RESOURCE=
+ PPP2XHTML_WIN32_RESOURCE=
]
)
AC_MSG_RESULT([$native_win32])
AM_CONDITIONAL(OS_WIN32, [test "x$native_win32" = "xyes"])
AC_SUBST(LIBPGPLUS_WIN32_RESOURCE)
-AC_SUBST(PUB2RAW_WIN32_RESOURCE)
-AC_SUBST(PUB2XHTML_WIN32_RESOURCE)
+AC_SUBST(PPP2RAW_WIN32_RESOURCE)
+AC_SUBST(PPP2XHTML_WIN32_RESOURCE)
AC_MSG_CHECKING([for Win32 platform in general])
AS_CASE([$host],
@@ -191,9 +191,9 @@ Makefile
src/Makefile
src/conv/Makefile
src/conv/raw/Makefile
-src/conv/raw/pub2raw.rc
+src/conv/raw/ppp2raw.rc
src/conv/svg/Makefile
-src/conv/svg/pub2xhtml.rc
+src/conv/svg/ppp2xhtml.rc
src/lib/Makefile
src/lib/libpgplus.rc
build/Makefile
diff --git a/libpgplus-0.0.pc.in b/libpgplus-0.0.pc.in
index bbc11c9..7c602d5 100644
--- a/libpgplus-0.0.pc.in
+++ b/libpgplus-0.0.pc.in
@@ -4,8 +4,8 @@ libdir=@libdir@
includedir=@includedir@
Name: libpgplus-@PGPLUS_MAJOR_VERSION@.@PGPLUS_MINOR_VERSION@
-Description: Library for parsing the Microsoft Publisher file format structure
+Description: Library for parsing the PagePlus file format structure
Version: @VERSION@
Requires: libwpd-0.9 libwpd-stream-0.9 libwpg-0.2
-Libs: -L${libdir} -lmspub-@PGPLUS_MAJOR_VERSION@.@PGPLUS_MINOR_VERSION@
+Libs: -L${libdir} -lpgplus-@PGPLUS_MAJOR_VERSION@.@PGPLUS_MINOR_VERSION@
Cflags: -I${includedir}/libpgplus-@PGPLUS_MAJOR_VERSION@.@PGPLUS_MINOR_VERSION@
diff --git a/libmspub.spec.in b/libpgplus.spec.in
index e384758..9d2d83c 100644
--- a/libmspub.spec.in
+++ b/libpgplus.spec.in
@@ -4,7 +4,7 @@
%define release %{?CUSTOM_RELEASE} %{!?CUSTOM_RELEASE:%RELEASE}
Name: %{name}
-Summary: Library for importing and converting Microsoft Publisher Documents
+Summary: Library for importing and converting PagePlus Documents
Version: %{version}
Release: %{release}
Source: %{name}-%{version}.tar.gz
diff --git a/src/conv/raw/.gitignore b/src/conv/raw/.gitignore
index 3e93fbe..816c109 100644
--- a/src/conv/raw/.gitignore
+++ b/src/conv/raw/.gitignore
@@ -4,6 +4,6 @@
*.la
Makefile
Makefile.in
-pub2raw
-pub2raw.exe
+ppp2raw
+ppp2raw.exe
*.rc
diff --git a/src/conv/raw/Makefile.am b/src/conv/raw/Makefile.am
index 2be9f6b..12a8cbf 100644
--- a/src/conv/raw/Makefile.am
+++ b/src/conv/raw/Makefile.am
@@ -2,13 +2,13 @@ bin_PROGRAMS = ppp2raw
AM_CXXFLAGS = -I$(top_srcdir)/src/lib -I$(top_builddir)/src/lib $(LIBPGPLUS_CXXFLAGS) $(DEBUG_CXXFLAGS)
-ppp2raw_DEPENDENCIES = @PUB2RAW_WIN32_RESOURCE@
+ppp2raw_DEPENDENCIES = @PPP2RAW_WIN32_RESOURCE@
if STATIC_TOOLS
-ppp2raw_LDADD = ../../lib/@PGPLUS_OBJDIR@/libpgplus-@PGPLUS_MAJOR_VERSION@.@PGPLUS_MINOR_VERSION@.a $(LIBPGPLUS_LIBS) @PUB2RAW_WIN32_RESOURCE@
+ppp2raw_LDADD = ../../lib/@PGPLUS_OBJDIR@/libpgplus-@PGPLUS_MAJOR_VERSION@.@PGPLUS_MINOR_VERSION@.a $(LIBPGPLUS_LIBS) @PPP2RAW_WIN32_RESOURCE@
ppp2raw_LDFLAGS = -all-static
else
-ppp2raw_LDADD = ../../lib/libpgplus-@PGPLUS_MAJOR_VERSION@.@PGPLUS_MINOR_VERSION@.la $(LIBPGPLUS_LIBS) @PUB2RAW_WIN32_RESOURCE@
+ppp2raw_LDADD = ../../lib/libpgplus-@PGPLUS_MAJOR_VERSION@.@PGPLUS_MINOR_VERSION@.la $(LIBPGPLUS_LIBS) @PPP2RAW_WIN32_RESOURCE@
endif
ppp2raw_SOURCES = \
@@ -16,9 +16,9 @@ ppp2raw_SOURCES = \
if OS_WIN32
-@PUB2RAW_WIN32_RESOURCE@ : ppp2raw.rc $(ppp2raw_OBJECTS)
+@PPP2RAW_WIN32_RESOURCE@ : ppp2raw.rc $(ppp2raw_OBJECTS)
chmod +x $(top_srcdir)/build/win32/*compile-resource
- WINDRES=@WINDRES@ $(top_srcdir)/build/win32/lt-compile-resource ppp2raw.rc @PUB2RAW_WIN32_RESOURCE@
+ WINDRES=@WINDRES@ $(top_srcdir)/build/win32/lt-compile-resource ppp2raw.rc @PPP2RAW_WIN32_RESOURCE@
endif
EXTRA_DIST = \
diff --git a/src/conv/raw/ppp2raw.cpp b/src/conv/raw/ppp2raw.cpp
index e4638b7..eb91ed9 100644
--- a/src/conv/raw/ppp2raw.cpp
+++ b/src/conv/raw/ppp2raw.cpp
@@ -214,7 +214,7 @@ namespace
int printUsage()
{
- printf("Usage: ppp2raw [OPTION] <Microsoft Publisher Document>\n");
+ printf("Usage: ppp2raw [OPTION] <PagePlus Document>\n");
printf("\n");
printf("Options:\n");
printf("--help Shows this help message\n");
diff --git a/src/conv/svg/.gitignore b/src/conv/svg/.gitignore
index 3ef58b3..f8be790 100644
--- a/src/conv/svg/.gitignore
+++ b/src/conv/svg/.gitignore
@@ -4,8 +4,8 @@
*.la
Makefile
Makefile.in
-pub2svg
-pub2svg.exe
-pub2xhtml
-pub2xhtml.exe
+ppp2svg
+ppp2svg.exe
+ppp2xhtml
+ppp2xhtml.exe
*.rc
diff --git a/src/conv/svg/Makefile.am b/src/conv/svg/Makefile.am
index cdcb53f..b4568cd 100644
--- a/src/conv/svg/Makefile.am
+++ b/src/conv/svg/Makefile.am
@@ -2,13 +2,13 @@ bin_PROGRAMS = ppp2xhtml
AM_CXXFLAGS = -I$(top_srcdir)/src/lib -I$(top_builddir)/src/lib $(LIBPGPLUS_CXXFLAGS) $(DEBUG_CXXFLAGS)
-ppp2xhtml_DEPENDENCIES = @PUB2XHTML_WIN32_RESOURCE@
+ppp2xhtml_DEPENDENCIES = @PPP2XHTML_WIN32_RESOURCE@
if STATIC_TOOLS
-ppp2xhtml_LDADD = ../../lib/@PGPLUS_OBJDIR@/libpgplus-@PGPLUS_MAJOR_VERSION@.@PGPLUS_MINOR_VERSION@.a $(LIBPGPLUS_LIBS) @PUB2XHTML_WIN32_RESOURCE@
+ppp2xhtml_LDADD = ../../lib/@PGPLUS_OBJDIR@/libpgplus-@PGPLUS_MAJOR_VERSION@.@PGPLUS_MINOR_VERSION@.a $(LIBPGPLUS_LIBS) @PPP2XHTML_WIN32_RESOURCE@
ppp2xhtml_LDFLAGS = -all-static
else
-ppp2xhtml_LDADD = ../../lib/libpgplus-@PGPLUS_MAJOR_VERSION@.@PGPLUS_MINOR_VERSION@.la $(LIBPGPLUS_LIBS) @PUB2XHTML_WIN32_RESOURCE@
+ppp2xhtml_LDADD = ../../lib/libpgplus-@PGPLUS_MAJOR_VERSION@.@PGPLUS_MINOR_VERSION@.la $(LIBPGPLUS_LIBS) @PPP2XHTML_WIN32_RESOURCE@
endif
ppp2xhtml_SOURCES = \
@@ -16,9 +16,9 @@ ppp2xhtml_SOURCES = \
if OS_WIN32
-@PUB2XHTML_WIN32_RESOURCE@ : ppp2xhtml.rc $(ppp2xhtml_OBJECTS)
+@PPP2XHTML_WIN32_RESOURCE@ : ppp2xhtml.rc $(ppp2xhtml_OBJECTS)
chmod +x $(top_srcdir)/build/win32/*compile-resource
- WINDRES=@WINDRES@ $(top_srcdir)/build/win32/lt-compile-resource ppp2xhtml.rc @PUB2XHTML_WIN32_RESOURCE@
+ WINDRES=@WINDRES@ $(top_srcdir)/build/win32/lt-compile-resource ppp2xhtml.rc @PPP2XHTML_WIN32_RESOURCE@
endif
EXTRA_DIST = \
diff --git a/src/conv/svg/ppp2xhtml.cpp b/src/conv/svg/ppp2xhtml.cpp
index d439292..6d4f303 100644
--- a/src/conv/svg/ppp2xhtml.cpp
+++ b/src/conv/svg/ppp2xhtml.cpp
@@ -41,7 +41,7 @@ namespace
int printUsage()
{
- printf("Usage: vsd2xhtml [OPTION] <Microsoft Publisher Document>\n");
+ printf("Usage: vsd2xhtml [OPTION] <PagePlus Document>\n");
printf("\n");
printf("Options:\n");
printf("--help Shows this help message\n");
diff --git a/src/lib/.gitignore b/src/lib/.gitignore
index c086f3e..3273b70 100644
--- a/src/lib/.gitignore
+++ b/src/lib/.gitignore
@@ -6,4 +6,3 @@
*.rc
Makefile
Makefile.in
-libwpg.h
diff --git a/src/lib/MSPUBCollector.cpp b/src/lib/PGPLUSCollector.cpp
index 31f99ac..31f99ac 100644
--- a/src/lib/MSPUBCollector.cpp
+++ b/src/lib/PGPLUSCollector.cpp
diff --git a/src/lib/MSPUBCollector.h b/src/lib/PGPLUSCollector.h
index a692d63..a692d63 100644
--- a/src/lib/MSPUBCollector.h
+++ b/src/lib/PGPLUSCollector.h
diff --git a/src/lib/MSPUBDocument.cpp b/src/lib/PGPLUSDocument.cpp
index fb7d848..ef4f77f 100644
--- a/src/lib/MSPUBDocument.cpp
+++ b/src/lib/PGPLUSDocument.cpp
@@ -30,30 +30,10 @@
Analyzes the content of an input stream to see if it can be parsed
\param input The input stream
\return A value that indicates whether the content from the input
-stream is a Microsoft Publisher Document that libpgplus is able to parse
+stream is a PagePlus Document that libpgplus is able to parse
*/
bool libpgplus::PGPLUSDocument::isSupported(WPXInputStream *input)
{
- if (!input->isOLEStream())
- return false;
- WPXInputStream *tmpStream = input->getDocumentOLEStream("Quill/QuillSub/CONTENTS");
- if (tmpStream == 0)
- return false;
- delete tmpStream;
- tmpStream = input->getDocumentOLEStream("Escher/EscherStm");
- if (tmpStream == 0)
- return false;
- delete tmpStream;
- tmpStream = input->getDocumentOLEStream("Contents");
- if (tmpStream == 0)
- return false;
- // Check the magic signature at the beginning of the Contents stream
- if (0xe8 == readU8(tmpStream) && 0xac == readU8(tmpStream) && 0x2c == readU8(tmpStream) && 0x00 == readU8(tmpStream))
- {
- delete tmpStream;
- return true;
- }
- delete tmpStream;
return false;
}
diff --git a/src/lib/MSPUBDocument.h b/src/lib/PGPLUSDocument.h
index 7ca2be1..7ca2be1 100644
--- a/src/lib/MSPUBDocument.h
+++ b/src/lib/PGPLUSDocument.h
diff --git a/src/lib/MSPUBParser.cpp b/src/lib/PGPLUSParser.cpp
index edf783e..860681e 100644
--- a/src/lib/MSPUBParser.cpp
+++ b/src/lib/PGPLUSParser.cpp
@@ -44,51 +44,22 @@ libpgplus::PGPLUSParser::~PGPLUSParser()
bool libpgplus::PGPLUSParser::parse()
{
- if (!m_input->isOLEStream())
- return false;
- WPXInputStream *quill = m_input->getDocumentOLEStream("Quill/QuillSub/CONTENTS");
- if (!quill)
- return false;
- if (!parseQuill(quill, m_collector))
- {
- delete quill;
- return false;
- }
- delete quill;
- WPXInputStream *escher = m_input->getDocumentOLEStream("Escher/EscherStm");
- if (!escher)
- return false;
- if (!parseEscher(escher, m_collector))
- {
- delete escher;
- return false;
- }
- delete escher;
- WPXInputStream *contents = m_input->getDocumentOLEStream("CONTENTS");
- if (!contents)
- return false;
- if (!parseContents(contents, m_collector))
- {
- delete contents;
- return false;
- }
- delete contents;
- return true;
+ return false;
}
bool libpgplus::PGPLUSParser::parseContents(WPXInputStream *input, libpgplus::PGPLUSCollector *collector)
{
- return true;
+ return false;
}
bool libpgplus::PGPLUSParser::parseQuill(WPXInputStream *input, libpgplus::PGPLUSCollector *collector)
{
- return true;
+ return false;
}
bool libpgplus::PGPLUSParser::parseEscher(WPXInputStream *input, libpgplus::PGPLUSCollector *collector)
{
- return true;
+ return false;
}
diff --git a/src/lib/MSPUBParser.h b/src/lib/PGPLUSParser.h
index 32eac84..32eac84 100644
--- a/src/lib/MSPUBParser.h
+++ b/src/lib/PGPLUSParser.h
diff --git a/src/lib/MSPUBSVGGenerator.cpp b/src/lib/PGPLUSSVGGenerator.cpp
index e60afec..e60afec 100644
--- a/src/lib/MSPUBSVGGenerator.cpp
+++ b/src/lib/PGPLUSSVGGenerator.cpp
diff --git a/src/lib/MSPUBSVGGenerator.h b/src/lib/PGPLUSSVGGenerator.h
index 42b87cb..42b87cb 100644
--- a/src/lib/MSPUBSVGGenerator.h
+++ b/src/lib/PGPLUSSVGGenerator.h
diff --git a/src/lib/MSPUBStringVector.cpp b/src/lib/PGPLUSStringVector.cpp
index a950185..a950185 100644
--- a/src/lib/MSPUBStringVector.cpp
+++ b/src/lib/PGPLUSStringVector.cpp
diff --git a/src/lib/MSPUBStringVector.h b/src/lib/PGPLUSStringVector.h
index b18ec59..b18ec59 100644
--- a/src/lib/MSPUBStringVector.h
+++ b/src/lib/PGPLUSStringVector.h
diff --git a/src/lib/libmspub.h b/src/lib/libpgplus.h
index 17453e2..17453e2 100644
--- a/src/lib/libmspub.h
+++ b/src/lib/libpgplus.h
diff --git a/src/lib/libmspub.rc.in b/src/lib/libpgplus.rc.in
index 432eb25..432eb25 100644
--- a/src/lib/libmspub.rc.in
+++ b/src/lib/libpgplus.rc.in
diff --git a/src/lib/libmspub_utils.cpp b/src/lib/libpgplus_utils.cpp
index c84e107..c84e107 100644
--- a/src/lib/libmspub_utils.cpp
+++ b/src/lib/libpgplus_utils.cpp
diff --git a/src/lib/libmspub_utils.h b/src/lib/libpgplus_utils.h
index f0d79c2..f0d79c2 100644
--- a/src/lib/libmspub_utils.h
+++ b/src/lib/libpgplus_utils.h
diff --git a/src/lib/makefile.mk b/src/lib/makefile.mk
index 58b83d2..2676554 100644
--- a/src/lib/makefile.mk
+++ b/src/lib/makefile.mk
@@ -3,7 +3,7 @@ EXTERNAL_WARNINGS_NOT_ERRORS := TRUE
PRJ=..$/..$/..$/..$/..$/..
PRJNAME=libpgplus
-TARGET=mspublib
+TARGET=pgpluslib
ENABLE_EXCEPTIONS=TRUE
LIBTARGET=NO
@@ -29,7 +29,10 @@ INCPRE+=$(SOLARVER)$/$(INPATH)$/inc$/libwpg
.ENDIF
SLOFILES= \
+ $(SLO)$/PGPLUSCollector.obj \
$(SLO)$/PGPLUSDocument.obj \
+ $(SLO)$/PGPLUSParser.obj \
+ $(SLO)$/PGPLUSStringVector.obj \
$(SLO)$/PGPLUSSVGGenerator.obj \
$(SLO)$/libpgplus_utils.obj