initial commit
Signed-off-by: Peter Siegmund <mars3142@noreply.mars3142.dev>
This commit is contained in:
76
libs/wxWidgets-3.3.1/samples/docview/Info.plist.in
Normal file
76
libs/wxWidgets-3.3.1/samples/docview/Info.plist.in
Normal file
@@ -0,0 +1,76 @@
|
||||
<?xml version="1.0" encoding="UTF-8"?>
|
||||
<!DOCTYPE plist PUBLIC "-//Apple//DTD PLIST 1.0//EN" "http://www.apple.com/DTDs/PropertyList-1.0.dtd">
|
||||
<plist version="1.0">
|
||||
<dict>
|
||||
<key>CFBundleDevelopmentRegion</key>
|
||||
<string>English</string>
|
||||
<key>CFBundleDocumentTypes</key>
|
||||
<array>
|
||||
<dict>
|
||||
<key>CFBundleTypeExtensions</key>
|
||||
<array>
|
||||
<string>drw</string>
|
||||
</array>
|
||||
<key>CFBundleTypeIconFile</key>
|
||||
<string>chart.icns</string>
|
||||
<key>CFBundleTypeName</key>
|
||||
<string>DocView Drawing</string>
|
||||
<key>CFBundleTypeOSTypes</key>
|
||||
<array>
|
||||
<string>WXMB</string>
|
||||
</array>
|
||||
<key>CFBundleTypeRole</key>
|
||||
<string>Editor</string>
|
||||
<key>LSTypeIsPackage</key>
|
||||
<false/>
|
||||
<key>NSPersistentStoreTypeKey</key>
|
||||
<string>Binary</string>
|
||||
</dict>
|
||||
<dict>
|
||||
<key>CFBundleTypeExtensions</key>
|
||||
<array>
|
||||
<string>txt</string>
|
||||
<string>text</string>
|
||||
</array>
|
||||
<key>CFBundleTypeIconFile</key>
|
||||
<string>notepad.icns</string>
|
||||
<key>CFBundleTypeName</key>
|
||||
<string>DocView Text</string>
|
||||
<key>CFBundleTypeOSTypes</key>
|
||||
<array>
|
||||
<string>TEXT</string>
|
||||
</array>
|
||||
<key>CFBundleTypeRole</key>
|
||||
<string>Editor</string>
|
||||
<key>LSTypeIsPackage</key>
|
||||
<false/>
|
||||
<key>NSPersistentStoreTypeKey</key>
|
||||
<string>Binary</string>
|
||||
</dict>
|
||||
</array>
|
||||
<key>CFBundleExecutable</key>
|
||||
<string>${MACOSX_BUNDLE_EXECUTABLE_NAME}</string>
|
||||
<key>CFBundleGetInfoString</key>
|
||||
<string>${MACOSX_BUNDLE_INFO_STRING}</string>
|
||||
<key>CFBundleIconFile</key>
|
||||
<string>wxmac.icns</string>
|
||||
<key>CFBundleIdentifier</key>
|
||||
<string>${MACOSX_BUNDLE_GUI_IDENTIFIER}</string>
|
||||
<key>CFBundleInfoDictionaryVersion</key>
|
||||
<string>6.0</string>
|
||||
<key>CFBundleLongVersionString</key>
|
||||
<string>${MACOSX_BUNDLE_LONG_VERSION_STRING}</string>
|
||||
<key>CFBundleName</key>
|
||||
<string>${MACOSX_BUNDLE_BUNDLE_NAME}</string>
|
||||
<key>CFBundlePackageType</key>
|
||||
<string>APPL</string>
|
||||
<key>CFBundleShortVersionString</key>
|
||||
<string>${MACOSX_BUNDLE_SHORT_VERSION_STRING}</string>
|
||||
<key>CFBundleVersion</key>
|
||||
<string>${MACOSX_BUNDLE_BUNDLE_VERSION}</string>
|
||||
<key>NSHumanReadableCopyright</key>
|
||||
<string>${MACOSX_BUNDLE_COPYRIGHT}</string>
|
||||
<key>NSPrincipalClass</key>
|
||||
<string>wxNSApplication</string>
|
||||
</dict>
|
||||
</plist>
|
||||
212
libs/wxWidgets-3.3.1/samples/docview/Makefile.in
Normal file
212
libs/wxWidgets-3.3.1/samples/docview/Makefile.in
Normal file
@@ -0,0 +1,212 @@
|
||||
# =========================================================================
|
||||
# This makefile was generated by
|
||||
# Bakefile 0.2.13 (http://www.bakefile.org)
|
||||
# Do not modify, all changes will be overwritten!
|
||||
# =========================================================================
|
||||
|
||||
|
||||
@MAKE_SET@
|
||||
|
||||
prefix = @prefix@
|
||||
exec_prefix = @exec_prefix@
|
||||
datarootdir = @datarootdir@
|
||||
INSTALL = @INSTALL@
|
||||
EXEEXT = @EXEEXT@
|
||||
WINDRES = @WINDRES@
|
||||
NM = @NM@
|
||||
BK_DEPS = @BK_DEPS@
|
||||
srcdir = @srcdir@
|
||||
top_srcdir = @top_srcdir@
|
||||
LIBS = @LIBS@
|
||||
LDFLAGS_GUI = @LDFLAGS_GUI@
|
||||
CXX = @CXX@
|
||||
CXXFLAGS = @CXXFLAGS@
|
||||
CPPFLAGS = @CPPFLAGS@
|
||||
LDFLAGS = @LDFLAGS@
|
||||
USE_DPI_AWARE_MANIFEST = @USE_DPI_AWARE_MANIFEST@
|
||||
WX_LIB_FLAVOUR = @WX_LIB_FLAVOUR@
|
||||
TOOLKIT = @TOOLKIT@
|
||||
TOOLKIT_LOWERCASE = @TOOLKIT_LOWERCASE@
|
||||
TOOLKIT_VERSION = @TOOLKIT_VERSION@
|
||||
TOOLCHAIN_FULLNAME = @TOOLCHAIN_FULLNAME@
|
||||
EXTRALIBS = @EXTRALIBS@
|
||||
EXTRALIBS_XML = @EXTRALIBS_XML@
|
||||
EXTRALIBS_GUI = @EXTRALIBS_GUI@
|
||||
WX_CPPFLAGS = @WX_CPPFLAGS@
|
||||
WX_CXXFLAGS = @WX_CXXFLAGS@
|
||||
WX_LDFLAGS = @WX_LDFLAGS@
|
||||
HOST_SUFFIX = @HOST_SUFFIX@
|
||||
DYLIB_RPATH_FLAG = @DYLIB_RPATH_FLAG@
|
||||
SAMPLES_CXXFLAGS = @SAMPLES_CXXFLAGS@
|
||||
wx_top_builddir = @wx_top_builddir@
|
||||
|
||||
### Variables: ###
|
||||
|
||||
DESTDIR =
|
||||
WX_RELEASE = 3.3
|
||||
WX_VERSION = $(WX_RELEASE).1
|
||||
LIBDIRNAME = $(wx_top_builddir)/lib
|
||||
DOCVIEW_CXXFLAGS = $(WX_CPPFLAGS) -D__WX$(TOOLKIT)__ $(__WXUNIV_DEFINE_p) \
|
||||
$(__DEBUG_DEFINE_p) $(__EXCEPTIONS_DEFINE_p) $(__RTTI_DEFINE_p) \
|
||||
$(__THREAD_DEFINE_p) -I$(srcdir) $(__DLLFLAG_p) -I$(srcdir)/../../samples \
|
||||
$(WX_CXXFLAGS) $(SAMPLES_CXXFLAGS) $(CPPFLAGS) $(CXXFLAGS)
|
||||
DOCVIEW_OBJECTS = \
|
||||
docview_docview.o \
|
||||
docview_doc.o \
|
||||
docview_view.o \
|
||||
$(__docview___win32rc)
|
||||
|
||||
### Conditionally set variables: ###
|
||||
|
||||
@COND_DEPS_TRACKING_0@CXXC = $(CXX)
|
||||
@COND_DEPS_TRACKING_1@CXXC = $(BK_DEPS) $(CXX)
|
||||
@COND_USE_GUI_0@PORTNAME = base
|
||||
@COND_USE_GUI_1@PORTNAME = $(TOOLKIT_LOWERCASE)$(TOOLKIT_VERSION)
|
||||
@COND_TOOLKIT_MAC@WXBASEPORT = _carbon
|
||||
@COND_BUILD_debug@WXDEBUGFLAG = d
|
||||
@COND_WXUNIV_1@WXUNIVNAME = univ
|
||||
@COND_MONOLITHIC_0@EXTRALIBS_FOR_BASE = $(EXTRALIBS)
|
||||
@COND_MONOLITHIC_1@EXTRALIBS_FOR_BASE = $(EXTRALIBS) \
|
||||
@COND_MONOLITHIC_1@ $(EXTRALIBS_XML) $(EXTRALIBS_GUI)
|
||||
@COND_MONOLITHIC_0@EXTRALIBS_FOR_GUI = $(EXTRALIBS_GUI)
|
||||
@COND_MONOLITHIC_1@EXTRALIBS_FOR_GUI =
|
||||
@COND_WXUNIV_1@__WXUNIV_DEFINE_p = -D__WXUNIVERSAL__
|
||||
@COND_WXUNIV_1@__WXUNIV_DEFINE_p_1 = --define __WXUNIVERSAL__
|
||||
@COND_DEBUG_FLAG_0@__DEBUG_DEFINE_p = -DwxDEBUG_LEVEL=0
|
||||
@COND_DEBUG_FLAG_0@__DEBUG_DEFINE_p_1 = --define wxDEBUG_LEVEL=0
|
||||
@COND_USE_EXCEPTIONS_0@__EXCEPTIONS_DEFINE_p = -DwxNO_EXCEPTIONS
|
||||
@COND_USE_EXCEPTIONS_0@__EXCEPTIONS_DEFINE_p_1 = --define wxNO_EXCEPTIONS
|
||||
@COND_USE_RTTI_0@__RTTI_DEFINE_p = -DwxNO_RTTI
|
||||
@COND_USE_RTTI_0@__RTTI_DEFINE_p_1 = --define wxNO_RTTI
|
||||
@COND_USE_THREADS_0@__THREAD_DEFINE_p = -DwxNO_THREADS
|
||||
@COND_USE_THREADS_0@__THREAD_DEFINE_p_1 = --define wxNO_THREADS
|
||||
@COND_SHARED_1@__DLLFLAG_p = -DWXUSINGDLL
|
||||
@COND_SHARED_1@__DLLFLAG_p_1 = --define WXUSINGDLL
|
||||
@COND_PLATFORM_WIN32_1@__WIN32_DPI_MANIFEST_p = \
|
||||
@COND_PLATFORM_WIN32_1@ --define \
|
||||
@COND_PLATFORM_WIN32_1@ wxUSE_DPI_AWARE_MANIFEST=$(USE_DPI_AWARE_MANIFEST)
|
||||
COND_PLATFORM_OS2_1___docview___os2_emxbindcmd = $(NM) docview$(EXEEXT) | if \
|
||||
grep -q pmwin.763 ; then emxbind -ep docview$(EXEEXT) ; fi
|
||||
@COND_PLATFORM_OS2_1@__docview___os2_emxbindcmd = $(COND_PLATFORM_OS2_1___docview___os2_emxbindcmd)
|
||||
@COND_TOOLKIT_MSW@__RCDEFDIR_p = --include-dir \
|
||||
@COND_TOOLKIT_MSW@ $(LIBDIRNAME)/wx/include/$(TOOLCHAIN_FULLNAME)
|
||||
@COND_PLATFORM_MACOSX_1@__docview_app_Contents_PkgInfo___depname \
|
||||
@COND_PLATFORM_MACOSX_1@ = docview.app/Contents/PkgInfo
|
||||
@COND_PLATFORM_MACOSX_1@__docview_bundle___depname = docview_bundle
|
||||
@COND_TOOLKIT_MAC@____docview_BUNDLE_TGT_REF_DEP = \
|
||||
@COND_TOOLKIT_MAC@ $(__docview_app_Contents_PkgInfo___depname)
|
||||
@COND_TOOLKIT_OSX_CARBON@____docview_BUNDLE_TGT_REF_DEP \
|
||||
@COND_TOOLKIT_OSX_CARBON@ = $(__docview_app_Contents_PkgInfo___depname)
|
||||
@COND_TOOLKIT_OSX_COCOA@____docview_BUNDLE_TGT_REF_DEP \
|
||||
@COND_TOOLKIT_OSX_COCOA@ = $(__docview_app_Contents_PkgInfo___depname)
|
||||
@COND_TOOLKIT_OSX_IPHONE@____docview_BUNDLE_TGT_REF_DEP \
|
||||
@COND_TOOLKIT_OSX_IPHONE@ = $(__docview_app_Contents_PkgInfo___depname)
|
||||
@COND_TOOLKIT_COCOA@____docview_BUNDLE_TGT_REF_DEP = \
|
||||
@COND_TOOLKIT_COCOA@ $(__docview_app_Contents_PkgInfo___depname)
|
||||
COND_MONOLITHIC_0___WXLIB_AUI_p = \
|
||||
-lwx_$(PORTNAME)$(WXUNIVNAME)u$(WXDEBUGFLAG)$(WX_LIB_FLAVOUR)_aui-$(WX_RELEASE)$(HOST_SUFFIX)
|
||||
@COND_MONOLITHIC_0@__WXLIB_AUI_p = $(COND_MONOLITHIC_0___WXLIB_AUI_p)
|
||||
COND_MONOLITHIC_0___WXLIB_CORE_p = \
|
||||
-lwx_$(PORTNAME)$(WXUNIVNAME)u$(WXDEBUGFLAG)$(WX_LIB_FLAVOUR)_core-$(WX_RELEASE)$(HOST_SUFFIX)
|
||||
@COND_MONOLITHIC_0@__WXLIB_CORE_p = $(COND_MONOLITHIC_0___WXLIB_CORE_p)
|
||||
COND_MONOLITHIC_0___WXLIB_BASE_p = \
|
||||
-lwx_base$(WXBASEPORT)u$(WXDEBUGFLAG)$(WX_LIB_FLAVOUR)-$(WX_RELEASE)$(HOST_SUFFIX)
|
||||
@COND_MONOLITHIC_0@__WXLIB_BASE_p = $(COND_MONOLITHIC_0___WXLIB_BASE_p)
|
||||
@COND_PLATFORM_WIN32_1@__docview___win32rc = docview_docview_rc.o
|
||||
COND_MONOLITHIC_1___WXLIB_MONO_p = \
|
||||
-lwx_$(PORTNAME)$(WXUNIVNAME)u$(WXDEBUGFLAG)$(WX_LIB_FLAVOUR)-$(WX_RELEASE)$(HOST_SUFFIX)
|
||||
@COND_MONOLITHIC_1@__WXLIB_MONO_p = $(COND_MONOLITHIC_1___WXLIB_MONO_p)
|
||||
@COND_MONOLITHIC_1_USE_STC_1@__LIB_SCINTILLA_IF_MONO_p \
|
||||
@COND_MONOLITHIC_1_USE_STC_1@ = $(__LIB_SCINTILLA_p)
|
||||
@COND_USE_STC_1@__LIB_SCINTILLA_p = \
|
||||
@COND_USE_STC_1@ -lwxscintilla$(WXDEBUGFLAG)$(WX_LIB_FLAVOUR)-$(WX_RELEASE)$(HOST_SUFFIX)
|
||||
@COND_MONOLITHIC_1_USE_STC_1@__LIB_LEXILLA_IF_MONO_p = $(__LIB_LEXILLA_p)
|
||||
@COND_USE_STC_1@__LIB_LEXILLA_p = \
|
||||
@COND_USE_STC_1@ -lwxlexilla$(WXDEBUGFLAG)$(WX_LIB_FLAVOUR)-$(WX_RELEASE)$(HOST_SUFFIX)
|
||||
@COND_USE_GUI_1_wxUSE_LIBTIFF_builtin@__LIB_TIFF_p \
|
||||
@COND_USE_GUI_1_wxUSE_LIBTIFF_builtin@ = \
|
||||
@COND_USE_GUI_1_wxUSE_LIBTIFF_builtin@ -lwxtiff$(WXDEBUGFLAG)$(WX_LIB_FLAVOUR)-$(WX_RELEASE)$(HOST_SUFFIX)
|
||||
@COND_USE_GUI_1_wxUSE_LIBJPEG_builtin@__LIB_JPEG_p \
|
||||
@COND_USE_GUI_1_wxUSE_LIBJPEG_builtin@ = \
|
||||
@COND_USE_GUI_1_wxUSE_LIBJPEG_builtin@ -lwxjpeg$(WXDEBUGFLAG)$(WX_LIB_FLAVOUR)-$(WX_RELEASE)$(HOST_SUFFIX)
|
||||
@COND_USE_GUI_1_wxUSE_LIBPNG_builtin@__LIB_PNG_p \
|
||||
@COND_USE_GUI_1_wxUSE_LIBPNG_builtin@ = \
|
||||
@COND_USE_GUI_1_wxUSE_LIBPNG_builtin@ -lwxpng$(WXDEBUGFLAG)$(WX_LIB_FLAVOUR)-$(WX_RELEASE)$(HOST_SUFFIX)
|
||||
@COND_USE_GUI_1_wxUSE_LIBWEBP_builtin@__LIB_WEBP_p \
|
||||
@COND_USE_GUI_1_wxUSE_LIBWEBP_builtin@ = \
|
||||
@COND_USE_GUI_1_wxUSE_LIBWEBP_builtin@ -lwxwebp$(WXDEBUGFLAG)$(WX_LIB_FLAVOUR)-$(WX_RELEASE)$(HOST_SUFFIX)
|
||||
@COND_wxUSE_ZLIB_builtin@__LIB_ZLIB_p = \
|
||||
@COND_wxUSE_ZLIB_builtin@ -lwxzlib$(WXDEBUGFLAG)$(WX_LIB_FLAVOUR)-$(WX_RELEASE)$(HOST_SUFFIX)
|
||||
@COND_wxUSE_REGEX_builtin@__LIB_REGEX_p = \
|
||||
@COND_wxUSE_REGEX_builtin@ -lwxregexu$(WXDEBUGFLAG)$(WX_LIB_FLAVOUR)-$(WX_RELEASE)$(HOST_SUFFIX)
|
||||
@COND_wxUSE_EXPAT_builtin@__LIB_EXPAT_p = \
|
||||
@COND_wxUSE_EXPAT_builtin@ -lwxexpat$(WXDEBUGFLAG)$(WX_LIB_FLAVOUR)-$(WX_RELEASE)$(HOST_SUFFIX)
|
||||
|
||||
### Targets: ###
|
||||
|
||||
all: docview$(EXEEXT) $(__docview_bundle___depname)
|
||||
|
||||
install:
|
||||
|
||||
uninstall:
|
||||
|
||||
install-strip: install
|
||||
|
||||
clean:
|
||||
rm -rf ./.deps ./.pch
|
||||
rm -f ./*.o
|
||||
rm -f docview$(EXEEXT)
|
||||
rm -rf docview.app
|
||||
|
||||
distclean: clean
|
||||
rm -f config.cache config.log config.status bk-deps bk-make-pch Makefile
|
||||
|
||||
docview$(EXEEXT): $(DOCVIEW_OBJECTS) $(__docview___win32rc)
|
||||
$(CXX) -o $@ $(DOCVIEW_OBJECTS) -L$(LIBDIRNAME) $(DYLIB_RPATH_FLAG) $(LDFLAGS_GUI) $(LDFLAGS) $(WX_LDFLAGS) $(__WXLIB_AUI_p) $(__WXLIB_CORE_p) $(__WXLIB_BASE_p) $(__WXLIB_MONO_p) $(__LIB_SCINTILLA_IF_MONO_p) $(__LIB_LEXILLA_IF_MONO_p) $(__LIB_TIFF_p) $(__LIB_JPEG_p) $(__LIB_PNG_p) $(__LIB_WEBP_p) $(EXTRALIBS_FOR_GUI) $(__LIB_ZLIB_p) $(__LIB_REGEX_p) $(__LIB_EXPAT_p) $(EXTRALIBS_FOR_BASE) $(LIBS)
|
||||
$(__docview___os2_emxbindcmd)
|
||||
|
||||
@COND_PLATFORM_MACOSX_1@docview.app/Contents/PkgInfo: docview$(EXEEXT) $(srcdir)/Info.plist.in $(srcdir)/doc.icns $(srcdir)/chart.icns $(srcdir)/notepad.icns
|
||||
@COND_PLATFORM_MACOSX_1@ mkdir -p docview.app/Contents
|
||||
@COND_PLATFORM_MACOSX_1@ mkdir -p docview.app/Contents/MacOS
|
||||
@COND_PLATFORM_MACOSX_1@ mkdir -p docview.app/Contents/Resources
|
||||
@COND_PLATFORM_MACOSX_1@
|
||||
@COND_PLATFORM_MACOSX_1@
|
||||
@COND_PLATFORM_MACOSX_1@ sed -e "s/\$${MACOSX_BUNDLE_GUI_IDENTIFIER}/org.wxwidgets.docview/" \
|
||||
@COND_PLATFORM_MACOSX_1@ -e "s/\$${MACOSX_BUNDLE_EXECUTABLE_NAME}/docview/" \
|
||||
@COND_PLATFORM_MACOSX_1@ -e "s/\$${MACOSX_BUNDLE_BUNDLE_NAME}/docview/" \
|
||||
@COND_PLATFORM_MACOSX_1@ -e "s/\$${MACOSX_BUNDLE_COPYRIGHT}/Copyright 2002-2025 wxWidgets/" \
|
||||
@COND_PLATFORM_MACOSX_1@ -e "s/\$${MACOSX_BUNDLE_BUNDLE_VERSION}/$(WX_VERSION)/" \
|
||||
@COND_PLATFORM_MACOSX_1@ -e "s/\$${MACOSX_BUNDLE_INFO_STRING}/docview version $(WX_VERSION), (c) 2002-2025 wxWidgets/" \
|
||||
@COND_PLATFORM_MACOSX_1@ -e "s/\$${MACOSX_BUNDLE_LONG_VERSION_STRING}/$(WX_VERSION), (c) 2002-2025 wxWidgets/" \
|
||||
@COND_PLATFORM_MACOSX_1@ -e "s/\$${MACOSX_BUNDLE_SHORT_VERSION_STRING}/$(WX_RELEASE)/" \
|
||||
@COND_PLATFORM_MACOSX_1@ $(srcdir)/Info.plist.in >docview.app/Contents/Info.plist
|
||||
@COND_PLATFORM_MACOSX_1@
|
||||
@COND_PLATFORM_MACOSX_1@
|
||||
@COND_PLATFORM_MACOSX_1@ /bin/echo "APPL????" >docview.app/Contents/PkgInfo
|
||||
@COND_PLATFORM_MACOSX_1@
|
||||
@COND_PLATFORM_MACOSX_1@
|
||||
@COND_PLATFORM_MACOSX_1@ ln -f docview$(EXEEXT) docview.app/Contents/MacOS/docview
|
||||
@COND_PLATFORM_MACOSX_1@
|
||||
@COND_PLATFORM_MACOSX_1@
|
||||
@COND_PLATFORM_MACOSX_1@ cp -f $(srcdir)/doc.icns docview.app/Contents/Resources/wxmac.icns
|
||||
@COND_PLATFORM_MACOSX_1@ cp -f $(srcdir)/chart.icns $(srcdir)/notepad.icns docview.app/Contents/Resources
|
||||
|
||||
@COND_PLATFORM_MACOSX_1@docview_bundle: $(____docview_BUNDLE_TGT_REF_DEP)
|
||||
|
||||
docview_docview.o: $(srcdir)/docview.cpp
|
||||
$(CXXC) -c -o $@ $(DOCVIEW_CXXFLAGS) $(srcdir)/docview.cpp
|
||||
|
||||
docview_doc.o: $(srcdir)/doc.cpp
|
||||
$(CXXC) -c -o $@ $(DOCVIEW_CXXFLAGS) $(srcdir)/doc.cpp
|
||||
|
||||
docview_view.o: $(srcdir)/view.cpp
|
||||
$(CXXC) -c -o $@ $(DOCVIEW_CXXFLAGS) $(srcdir)/view.cpp
|
||||
|
||||
docview_docview_rc.o: $(srcdir)/docview.rc
|
||||
$(WINDRES) -i$< -o$@ --define __WX$(TOOLKIT)__ $(__WXUNIV_DEFINE_p_1) $(__DEBUG_DEFINE_p_1) $(__EXCEPTIONS_DEFINE_p_1) $(__RTTI_DEFINE_p_1) $(__THREAD_DEFINE_p_1) --include-dir $(srcdir) $(__DLLFLAG_p_1) $(__WIN32_DPI_MANIFEST_p) --include-dir $(srcdir)/../../samples $(__RCDEFDIR_p) --include-dir $(top_srcdir)/include
|
||||
|
||||
|
||||
# Include dependency info, if present:
|
||||
@IF_GNU_MAKE@-include ./.deps/*.d
|
||||
|
||||
.PHONY: all install uninstall clean distclean docview_bundle
|
||||
BIN
libs/wxWidgets-3.3.1/samples/docview/chart.icns
Normal file
BIN
libs/wxWidgets-3.3.1/samples/docview/chart.icns
Normal file
Binary file not shown.
BIN
libs/wxWidgets-3.3.1/samples/docview/chart.ico
Normal file
BIN
libs/wxWidgets-3.3.1/samples/docview/chart.ico
Normal file
Binary file not shown.
|
After Width: | Height: | Size: 766 B |
49
libs/wxWidgets-3.3.1/samples/docview/chart.xpm
Normal file
49
libs/wxWidgets-3.3.1/samples/docview/chart.xpm
Normal file
@@ -0,0 +1,49 @@
|
||||
/* XPM */
|
||||
static const char *chrt_xpm[] = {
|
||||
/* columns rows colors chars-per-pixel */
|
||||
"32 32 11 1",
|
||||
" c black",
|
||||
". c red",
|
||||
"X c #00BF00",
|
||||
"o c green",
|
||||
"O c yellow",
|
||||
"+ c blue",
|
||||
"@ c #00BFBF",
|
||||
"# c #808080",
|
||||
"$ c #C0C0C0",
|
||||
"% c gray100",
|
||||
"& c None",
|
||||
/* pixels */
|
||||
"&&&&&&&&&&&&&&&&&&&&&&&&&&&&&&&&",
|
||||
"&& &&&&&&",
|
||||
"&& ###################### &&&&&&",
|
||||
"&& &&&&&&",
|
||||
"&& %%%%%%%%%%%%%%%%%%%%%% &&&&&&",
|
||||
"&& %%%%%%%.....%%%%%%%%%% &&&&&&",
|
||||
"&& %%%%%%.......%%%%%%%%% &&&&&&",
|
||||
"&& %%%%%........+%%%%%%%% &&&&&&",
|
||||
"&& %%%%........+++%%%%%%% &&&&&&",
|
||||
"&& %%%%.......++++%%%%%%% &&&&&&",
|
||||
"&& %%%.......++++++%%%%%% &&&&&&",
|
||||
"&& %%%.... ",
|
||||
"&& %%%.... #################### ",
|
||||
"&& %%%%... ",
|
||||
"&& %%%%... %%%%%%%%%%%%%%%%%%%% ",
|
||||
"&& %%%%%.. %%#%%++%%%%%%%%%%%%% ",
|
||||
"&& %%%%%%. %%#%%++%%$$%%%%%%%%% ",
|
||||
"&& %%%%%%% %%#%%++%%$$%%%%%%%%% ",
|
||||
"&& %%%%%%% %%#oo++%%$$%%%% %%% ",
|
||||
"&& %%%%%%% %%#oo++%%$$%%%% %%% ",
|
||||
"&& %%#oo++%%$$%%%% %%% ",
|
||||
"&&&&&&&&&& %%#oo++OO$$%%XX %%% ",
|
||||
"&&&&&&&&&& %%#oo++OO$$%%XX %%% ",
|
||||
"&&&&&&&&&& %%#oo++OO$$@@XX %%% ",
|
||||
"&&&&&&&&&& %%#oo++OO$$@@XX %%% ",
|
||||
"&&&&&&&&&& %%#oo++OO$$@@XX %%% ",
|
||||
"&&&&&&&&&& %%#oo++OO$$@@XX %%% ",
|
||||
"&&&&&&&&&& %%#################% ",
|
||||
"&&&&&&&&&& %%%%%%%%%%%%%%%%%%%% ",
|
||||
"&&&&&&&&&& %%%%%%%%%%%%%%%%%%%% ",
|
||||
"&&&&&&&&&& ",
|
||||
"&&&&&&&&&&&&&&&&&&&&&&&&&&&&&&&&"
|
||||
};
|
||||
49
libs/wxWidgets-3.3.1/samples/docview/descrip.mms
Normal file
49
libs/wxWidgets-3.3.1/samples/docview/descrip.mms
Normal file
@@ -0,0 +1,49 @@
|
||||
#*****************************************************************************
|
||||
# *
|
||||
# Make file for VMS *
|
||||
# Author : J.Jansen (joukj@hrem.stm.tudelft.nl) *
|
||||
# Date : 2 November 2001 *
|
||||
# *
|
||||
#*****************************************************************************
|
||||
.first
|
||||
define wx [--.include.wx]
|
||||
|
||||
.ifdef __WXMOTIF__
|
||||
CXX_DEFINE = /define=(__WXMOTIF__=1)/name=(as_is,short)\
|
||||
/assume=(nostdnew,noglobal_array_new)
|
||||
.else
|
||||
.ifdef __WXGTK__
|
||||
CXX_DEFINE = /define=(__WXGTK__=1)/float=ieee/name=(as_is,short)/ieee=denorm\
|
||||
/assume=(nostdnew,noglobal_array_new)
|
||||
.else
|
||||
CXX_DEFINE =
|
||||
.endif
|
||||
.endif
|
||||
|
||||
.suffixes : .cpp
|
||||
|
||||
.cpp.obj :
|
||||
cxx $(CXXFLAGS)$(CXX_DEFINE) $(MMS$TARGET_NAME).cpp
|
||||
|
||||
all :
|
||||
.ifdef __WXMOTIF__
|
||||
$(MMS)$(MMSQUALIFIERS) docview.exe
|
||||
.else
|
||||
.ifdef __WXGTK__
|
||||
$(MMS)$(MMSQUALIFIERS) docview_gtk.exe
|
||||
.endif
|
||||
.endif
|
||||
|
||||
.ifdef __WXMOTIF__
|
||||
docview.exe : docview.obj,doc.obj,view.obj
|
||||
cxxlink docview,doc,view,[--.lib]vms/opt
|
||||
.else
|
||||
.ifdef __WXGTK__
|
||||
docview_gtk.exe : docview.obj,doc.obj,view.obj
|
||||
cxxlink/exec=docview_gtk.exe docview,doc,view,[--.lib]vms_gtk/opt
|
||||
.endif
|
||||
.endif
|
||||
|
||||
docview.obj : docview.cpp
|
||||
view.obj : view.cpp
|
||||
doc.obj : doc.cpp
|
||||
282
libs/wxWidgets-3.3.1/samples/docview/doc.cpp
Normal file
282
libs/wxWidgets-3.3.1/samples/docview/doc.cpp
Normal file
@@ -0,0 +1,282 @@
|
||||
/////////////////////////////////////////////////////////////////////////////
|
||||
// Name: samples/docview/doc.cpp
|
||||
// Purpose: Implements document functionality
|
||||
// Author: Julian Smart
|
||||
// Modified by: Vadim Zeitlin: merge with the MDI version and general cleanup
|
||||
// Created: 04/01/98
|
||||
// Copyright: (c) 1998 Julian Smart
|
||||
// (c) 2008 Vadim Zeitlin
|
||||
// Licence: wxWindows licence
|
||||
/////////////////////////////////////////////////////////////////////////////
|
||||
|
||||
// ----------------------------------------------------------------------------
|
||||
// headers
|
||||
// ----------------------------------------------------------------------------
|
||||
|
||||
// For compilers that support precompilation, includes "wx/wx.h".
|
||||
#include "wx/wxprec.h"
|
||||
|
||||
|
||||
#if !wxUSE_DOC_VIEW_ARCHITECTURE
|
||||
#error You must set wxUSE_DOC_VIEW_ARCHITECTURE to 1 in setup.h!
|
||||
#endif
|
||||
|
||||
#ifndef WX_PRECOMP
|
||||
#include "wx/wx.h"
|
||||
#endif
|
||||
|
||||
#if wxUSE_STD_IOSTREAM
|
||||
#include <iostream>
|
||||
#else
|
||||
#include "wx/txtstrm.h"
|
||||
#endif
|
||||
#include "wx/wfstream.h"
|
||||
|
||||
#include "doc.h"
|
||||
#include "view.h"
|
||||
|
||||
// ----------------------------------------------------------------------------
|
||||
// DrawingDocument implementation
|
||||
// ----------------------------------------------------------------------------
|
||||
|
||||
wxIMPLEMENT_DYNAMIC_CLASS(DrawingDocument, wxDocument);
|
||||
|
||||
DocumentOstream& DrawingDocument::SaveObject(DocumentOstream& ostream)
|
||||
{
|
||||
#if wxUSE_STD_IOSTREAM
|
||||
DocumentOstream& stream = ostream;
|
||||
#else
|
||||
wxTextOutputStream stream(ostream);
|
||||
#endif
|
||||
|
||||
wxDocument::SaveObject(ostream);
|
||||
|
||||
const wxInt32 count = m_doodleSegments.size();
|
||||
stream << count << '\n';
|
||||
|
||||
for ( int n = 0; n < count; n++ )
|
||||
{
|
||||
m_doodleSegments[n].SaveObject(ostream);
|
||||
stream << '\n';
|
||||
}
|
||||
|
||||
return ostream;
|
||||
}
|
||||
|
||||
DocumentIstream& DrawingDocument::LoadObject(DocumentIstream& istream)
|
||||
{
|
||||
#if wxUSE_STD_IOSTREAM
|
||||
DocumentIstream& stream = istream;
|
||||
#else
|
||||
wxTextInputStream stream(istream);
|
||||
#endif
|
||||
|
||||
wxDocument::LoadObject(istream);
|
||||
|
||||
wxInt32 count = 0;
|
||||
stream >> count;
|
||||
if ( count < 0 )
|
||||
{
|
||||
wxLogWarning("Drawing document corrupted: invalid segments count.");
|
||||
#if wxUSE_STD_IOSTREAM
|
||||
istream.clear(std::ios::badbit);
|
||||
#else
|
||||
istream.Reset(wxSTREAM_READ_ERROR);
|
||||
#endif
|
||||
return istream;
|
||||
}
|
||||
|
||||
for ( int n = 0; n < count; n++ )
|
||||
{
|
||||
DoodleSegment segment;
|
||||
segment.LoadObject(istream);
|
||||
m_doodleSegments.push_back(segment);
|
||||
}
|
||||
|
||||
return istream;
|
||||
}
|
||||
|
||||
void DrawingDocument::DoUpdate()
|
||||
{
|
||||
Modify(true);
|
||||
UpdateAllViews();
|
||||
}
|
||||
|
||||
void DrawingDocument::AddDoodleSegment(const DoodleSegment& segment)
|
||||
{
|
||||
m_doodleSegments.push_back(segment);
|
||||
|
||||
DoUpdate();
|
||||
}
|
||||
|
||||
bool DrawingDocument::PopLastSegment(DoodleSegment *segment)
|
||||
{
|
||||
if ( m_doodleSegments.empty() )
|
||||
return false;
|
||||
|
||||
if ( segment )
|
||||
*segment = m_doodleSegments.back();
|
||||
|
||||
m_doodleSegments.pop_back();
|
||||
|
||||
DoUpdate();
|
||||
|
||||
return true;
|
||||
}
|
||||
|
||||
// ----------------------------------------------------------------------------
|
||||
// DoodleSegment implementation
|
||||
// ----------------------------------------------------------------------------
|
||||
|
||||
DocumentOstream& DoodleSegment::SaveObject(DocumentOstream& ostream)
|
||||
{
|
||||
#if wxUSE_STD_IOSTREAM
|
||||
DocumentOstream& stream = ostream;
|
||||
#else
|
||||
wxTextOutputStream stream(ostream);
|
||||
#endif
|
||||
|
||||
const wxInt32 count = m_lines.size();
|
||||
stream << count << '\n';
|
||||
|
||||
for ( int n = 0; n < count; n++ )
|
||||
{
|
||||
const DoodleLine& line = m_lines[n];
|
||||
stream
|
||||
<< line.x1 << ' '
|
||||
<< line.y1 << ' '
|
||||
<< line.x2 << ' '
|
||||
<< line.y2 << '\n';
|
||||
}
|
||||
|
||||
return ostream;
|
||||
}
|
||||
|
||||
DocumentIstream& DoodleSegment::LoadObject(DocumentIstream& istream)
|
||||
{
|
||||
#if wxUSE_STD_IOSTREAM
|
||||
DocumentIstream& stream = istream;
|
||||
#else
|
||||
wxTextInputStream stream(istream);
|
||||
#endif
|
||||
|
||||
wxInt32 count = 0;
|
||||
stream >> count;
|
||||
|
||||
for ( int n = 0; n < count; n++ )
|
||||
{
|
||||
DoodleLine line;
|
||||
stream
|
||||
>> line.x1
|
||||
>> line.y1
|
||||
>> line.x2
|
||||
>> line.y2;
|
||||
m_lines.push_back(line);
|
||||
}
|
||||
|
||||
return istream;
|
||||
}
|
||||
|
||||
// ----------------------------------------------------------------------------
|
||||
// TextEditDocument: wxDocument and wxTextCtrl married
|
||||
// ----------------------------------------------------------------------------
|
||||
|
||||
wxIMPLEMENT_DYNAMIC_CLASS(TextEditDocument, wxDocument);
|
||||
|
||||
bool TextEditDocument::OnCreate(const wxString& path, long flags)
|
||||
{
|
||||
if ( !wxDocument::OnCreate(path, flags) )
|
||||
return false;
|
||||
|
||||
// subscribe to changes in the text control to update the document state
|
||||
// when it's modified
|
||||
GetTextCtrl()->Bind(wxEVT_TEXT, &TextEditDocument::OnTextChange, this);
|
||||
|
||||
return true;
|
||||
}
|
||||
|
||||
// Since text windows have their own method for saving to/loading from files,
|
||||
// we override DoSave/OpenDocument instead of Save/LoadObject
|
||||
bool TextEditDocument::DoSaveDocument(const wxString& filename)
|
||||
{
|
||||
return GetTextCtrl()->SaveFile(filename);
|
||||
}
|
||||
|
||||
bool TextEditDocument::DoOpenDocument(const wxString& filename)
|
||||
{
|
||||
if ( !GetTextCtrl()->LoadFile(filename) )
|
||||
return false;
|
||||
|
||||
// we're not modified by the user yet
|
||||
Modify(false);
|
||||
|
||||
return true;
|
||||
}
|
||||
|
||||
bool TextEditDocument::IsModified() const
|
||||
{
|
||||
wxTextCtrl* wnd = GetTextCtrl();
|
||||
return wxDocument::IsModified() || (wnd && wnd->IsModified());
|
||||
}
|
||||
|
||||
void TextEditDocument::Modify(bool modified)
|
||||
{
|
||||
wxDocument::Modify(modified);
|
||||
|
||||
wxTextCtrl* wnd = GetTextCtrl();
|
||||
if (wnd && !modified)
|
||||
{
|
||||
wnd->DiscardEdits();
|
||||
}
|
||||
}
|
||||
|
||||
void TextEditDocument::OnTextChange(wxCommandEvent& event)
|
||||
{
|
||||
Modify(true);
|
||||
|
||||
event.Skip();
|
||||
}
|
||||
|
||||
wxTextCtrl* TextEditDocument::GetTextCtrl() const
|
||||
{
|
||||
wxView* view = GetFirstView();
|
||||
return view ? wxStaticCast(view, TextEditView)->GetText() : nullptr;
|
||||
}
|
||||
|
||||
// ----------------------------------------------------------------------------
|
||||
// ImageDocument and ImageDetailsDocument implementation
|
||||
// ----------------------------------------------------------------------------
|
||||
|
||||
wxIMPLEMENT_DYNAMIC_CLASS(ImageDocument, wxDocument);
|
||||
|
||||
bool ImageDocument::DoOpenDocument(const wxString& file)
|
||||
{
|
||||
return m_image.LoadFile(file);
|
||||
}
|
||||
|
||||
bool ImageDocument::OnOpenDocument(const wxString& filename)
|
||||
{
|
||||
if ( !wxDocument::OnOpenDocument(filename) )
|
||||
return false;
|
||||
|
||||
// we don't have a wxDocTemplate for the image details document as it's
|
||||
// never created by wxWidgets automatically, instead just do it manually
|
||||
ImageDetailsDocument * const docDetails = new ImageDetailsDocument(this);
|
||||
docDetails->SetFilename(filename);
|
||||
|
||||
new ImageDetailsView(docDetails);
|
||||
|
||||
return true;
|
||||
}
|
||||
|
||||
ImageDetailsDocument::ImageDetailsDocument(ImageDocument *parent)
|
||||
: wxDocument(parent)
|
||||
{
|
||||
const wxImage image = parent->GetImage();
|
||||
|
||||
m_size.x = image.GetWidth();
|
||||
m_size.y = image.GetHeight();
|
||||
m_numColours = image.CountColours();
|
||||
m_type = image.GetType();
|
||||
m_hasAlpha = image.HasAlpha();
|
||||
}
|
||||
238
libs/wxWidgets-3.3.1/samples/docview/doc.h
Normal file
238
libs/wxWidgets-3.3.1/samples/docview/doc.h
Normal file
@@ -0,0 +1,238 @@
|
||||
/////////////////////////////////////////////////////////////////////////////
|
||||
// Name: samples/docview/doc.h
|
||||
// Purpose: Document classes
|
||||
// Author: Julian Smart
|
||||
// Modified by: Vadim Zeitlin: merge with the MDI version and general cleanup
|
||||
// Created: 04/01/98
|
||||
// Copyright: (c) 1998 Julian Smart
|
||||
// (c) 2008 Vadim Zeitlin
|
||||
// Licence: wxWindows licence
|
||||
/////////////////////////////////////////////////////////////////////////////
|
||||
|
||||
#ifndef _WX_SAMPLES_DOCVIEW_DOC_H_
|
||||
#define _WX_SAMPLES_DOCVIEW_DOC_H_
|
||||
|
||||
#include "wx/docview.h"
|
||||
#include "wx/cmdproc.h"
|
||||
#include "wx/vector.h"
|
||||
#include "wx/image.h"
|
||||
|
||||
// This sample is written to build both with wxUSE_STD_IOSTREAM==0 and 1, which
|
||||
// somewhat complicates its code but is necessary in order to support building
|
||||
// it under all platforms and in all build configurations
|
||||
//
|
||||
// In your own code you would normally use one set of the stream classes only
|
||||
// and so wouldn't need these typedefs and preprocessor conditions.
|
||||
#if wxUSE_STD_IOSTREAM
|
||||
typedef std::istream DocumentIstream;
|
||||
typedef std::ostream DocumentOstream;
|
||||
#else // !wxUSE_STD_IOSTREAM
|
||||
typedef wxInputStream DocumentIstream;
|
||||
typedef wxOutputStream DocumentOstream;
|
||||
#endif // wxUSE_STD_IOSTREAM/!wxUSE_STD_IOSTREAM
|
||||
|
||||
// ----------------------------------------------------------------------------
|
||||
// The document class and its helpers
|
||||
// ----------------------------------------------------------------------------
|
||||
|
||||
// Represents a line from one point to the other
|
||||
struct DoodleLine
|
||||
{
|
||||
DoodleLine() { /* leave fields uninitialized */ }
|
||||
|
||||
DoodleLine(const wxPoint& pt1, const wxPoint& pt2)
|
||||
: x1(pt1.x), y1(pt1.y), x2(pt2.x), y2(pt2.y)
|
||||
{
|
||||
}
|
||||
|
||||
wxInt32 x1;
|
||||
wxInt32 y1;
|
||||
wxInt32 x2;
|
||||
wxInt32 y2;
|
||||
};
|
||||
|
||||
typedef wxVector<DoodleLine> DoodleLines;
|
||||
|
||||
// Contains a list of lines: represents a mouse-down doodle
|
||||
class DoodleSegment
|
||||
{
|
||||
public:
|
||||
DocumentOstream& SaveObject(DocumentOstream& stream);
|
||||
DocumentIstream& LoadObject(DocumentIstream& stream);
|
||||
|
||||
bool IsEmpty() const { return m_lines.empty(); }
|
||||
void AddLine(const wxPoint& pt1, const wxPoint& pt2)
|
||||
{
|
||||
m_lines.push_back(DoodleLine(pt1, pt2));
|
||||
}
|
||||
const DoodleLines& GetLines() const { return m_lines; }
|
||||
|
||||
private:
|
||||
DoodleLines m_lines;
|
||||
};
|
||||
|
||||
typedef wxVector<DoodleSegment> DoodleSegments;
|
||||
|
||||
|
||||
// The drawing document (model) class itself
|
||||
class DrawingDocument : public wxDocument
|
||||
{
|
||||
public:
|
||||
DrawingDocument() : wxDocument() { }
|
||||
|
||||
DocumentOstream& SaveObject(DocumentOstream& stream) override;
|
||||
DocumentIstream& LoadObject(DocumentIstream& stream) override;
|
||||
|
||||
// add a new segment to the document
|
||||
void AddDoodleSegment(const DoodleSegment& segment);
|
||||
|
||||
// remove the last segment, if any, and copy it in the provided pointer if
|
||||
// not null and return true or return false and do nothing if there are no
|
||||
// segments
|
||||
bool PopLastSegment(DoodleSegment *segment);
|
||||
|
||||
// get direct access to our segments (for DrawingView)
|
||||
const DoodleSegments& GetSegments() const { return m_doodleSegments; }
|
||||
|
||||
private:
|
||||
void DoUpdate();
|
||||
|
||||
DoodleSegments m_doodleSegments;
|
||||
|
||||
wxDECLARE_DYNAMIC_CLASS(DrawingDocument);
|
||||
};
|
||||
|
||||
|
||||
// ----------------------------------------------------------------------------
|
||||
// Some operations (which can be done and undone by the view) on the document:
|
||||
// ----------------------------------------------------------------------------
|
||||
|
||||
// Base class for all operations on DrawingDocument
|
||||
class DrawingCommand : public wxCommand
|
||||
{
|
||||
public:
|
||||
DrawingCommand(DrawingDocument *doc,
|
||||
const wxString& name,
|
||||
const DoodleSegment& segment = DoodleSegment())
|
||||
: wxCommand(true, name),
|
||||
m_doc(doc),
|
||||
m_segment(segment)
|
||||
{
|
||||
}
|
||||
|
||||
protected:
|
||||
bool DoAdd() { m_doc->AddDoodleSegment(m_segment); return true; }
|
||||
bool DoRemove() { return m_doc->PopLastSegment(&m_segment); }
|
||||
|
||||
private:
|
||||
DrawingDocument * const m_doc;
|
||||
DoodleSegment m_segment;
|
||||
};
|
||||
|
||||
// The command for adding a new segment
|
||||
class DrawingAddSegmentCommand : public DrawingCommand
|
||||
{
|
||||
public:
|
||||
DrawingAddSegmentCommand(DrawingDocument *doc, const DoodleSegment& segment)
|
||||
: DrawingCommand(doc, "Add new segment", segment)
|
||||
{
|
||||
}
|
||||
|
||||
virtual bool Do() override { return DoAdd(); }
|
||||
virtual bool Undo() override { return DoRemove(); }
|
||||
};
|
||||
|
||||
// The command for removing the last segment
|
||||
class DrawingRemoveSegmentCommand : public DrawingCommand
|
||||
{
|
||||
public:
|
||||
DrawingRemoveSegmentCommand(DrawingDocument *doc)
|
||||
: DrawingCommand(doc, "Remove last segment")
|
||||
{
|
||||
}
|
||||
|
||||
virtual bool Do() override { return DoRemove(); }
|
||||
virtual bool Undo() override { return DoAdd(); }
|
||||
};
|
||||
|
||||
|
||||
// ----------------------------------------------------------------------------
|
||||
// TextEditDocument: wxDocument implemented using wxTextCtrl
|
||||
// ----------------------------------------------------------------------------
|
||||
|
||||
class TextEditDocument : public wxDocument
|
||||
{
|
||||
public:
|
||||
TextEditDocument() : wxDocument() { }
|
||||
TextEditDocument(const TextEditDocument&) = delete;
|
||||
TextEditDocument &operator=(const TextEditDocument&) = delete;
|
||||
|
||||
virtual bool OnCreate(const wxString& path, long flags) override;
|
||||
|
||||
virtual bool IsModified() const override;
|
||||
virtual void Modify(bool mod) override;
|
||||
|
||||
protected:
|
||||
virtual bool DoSaveDocument(const wxString& filename) override;
|
||||
virtual bool DoOpenDocument(const wxString& filename) override;
|
||||
|
||||
private:
|
||||
wxTextCtrl* GetTextCtrl() const;
|
||||
|
||||
void OnTextChange(wxCommandEvent& event);
|
||||
|
||||
wxDECLARE_DYNAMIC_CLASS(TextEditDocument);
|
||||
};
|
||||
|
||||
// ----------------------------------------------------------------------------
|
||||
// Image and image details document classes (both are read-only for simplicity)
|
||||
// ----------------------------------------------------------------------------
|
||||
|
||||
// This is a normal document containing an image, just like TextEditDocument
|
||||
// above contains some text. It can be created from an image file on disk as
|
||||
// usual.
|
||||
class ImageDocument : public wxDocument
|
||||
{
|
||||
public:
|
||||
ImageDocument() : wxDocument() { }
|
||||
ImageDocument(const ImageDocument&) = delete;
|
||||
ImageDocument &operator=(const ImageDocument&) = delete;
|
||||
|
||||
virtual bool OnOpenDocument(const wxString& file) override;
|
||||
|
||||
wxImage GetImage() const { return m_image; }
|
||||
|
||||
protected:
|
||||
virtual bool DoOpenDocument(const wxString& file) override;
|
||||
|
||||
private:
|
||||
wxImage m_image;
|
||||
|
||||
wxDECLARE_DYNAMIC_CLASS(ImageDocument);
|
||||
};
|
||||
|
||||
// This is a child document of ImageDocument: this document doesn't
|
||||
// correspond to any file on disk, it's part of ImageDocument and can't be
|
||||
// instantiated independently of it.
|
||||
class ImageDetailsDocument : public wxDocument
|
||||
{
|
||||
public:
|
||||
ImageDetailsDocument(ImageDocument *parent);
|
||||
ImageDetailsDocument(const ImageDetailsDocument&) = delete;
|
||||
ImageDetailsDocument &operator=(const ImageDetailsDocument&) = delete;
|
||||
|
||||
// accessors for ImageDetailsView
|
||||
wxSize GetSize() const { return m_size; }
|
||||
unsigned long GetNumColours() const { return m_numColours; }
|
||||
wxBitmapType GetType() const { return m_type; }
|
||||
bool HasAlpha() const { return m_hasAlpha; }
|
||||
|
||||
private:
|
||||
// some information about the image we choose to show to the user
|
||||
wxSize m_size;
|
||||
unsigned long m_numColours;
|
||||
wxBitmapType m_type;
|
||||
bool m_hasAlpha;
|
||||
};
|
||||
|
||||
#endif // _WX_SAMPLES_DOCVIEW_DOC_H_
|
||||
BIN
libs/wxWidgets-3.3.1/samples/docview/doc.icns
Normal file
BIN
libs/wxWidgets-3.3.1/samples/docview/doc.icns
Normal file
Binary file not shown.
BIN
libs/wxWidgets-3.3.1/samples/docview/doc.ico
Normal file
BIN
libs/wxWidgets-3.3.1/samples/docview/doc.ico
Normal file
Binary file not shown.
|
After Width: | Height: | Size: 766 B |
43
libs/wxWidgets-3.3.1/samples/docview/doc.xpm
Normal file
43
libs/wxWidgets-3.3.1/samples/docview/doc.xpm
Normal file
@@ -0,0 +1,43 @@
|
||||
/* XPM */
|
||||
static const char *doc_xpm[] = {
|
||||
/* columns rows colors chars-per-pixel */
|
||||
"32 32 5 1",
|
||||
" c black",
|
||||
". c #808080",
|
||||
"X c #C0C0C0",
|
||||
"o c gray100",
|
||||
"O c None",
|
||||
/* pixels */
|
||||
"OOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOO",
|
||||
"OOOOOOOOOXXXXXXXXXXXXXXXXXXXOOOO",
|
||||
"OOOOOOOOOXoooooooooooooooooX.OOO",
|
||||
"OOOOOOOOOXoooooooooooooooooX.OOO",
|
||||
"OOOOOOXXXXXXXXXXXXXXXXXXXooX.OOO",
|
||||
"OOOOOOXoooooooooooooooooXooX.OOO",
|
||||
"OOOOOOXoooooooooooooooooXooX.OOO",
|
||||
"OOOXXXXXXXXXXXXXXXXXXXooXooX.OOO",
|
||||
"OOOXoooooooooooooooooXooXooX.OOO",
|
||||
"OOOXoooooooooooooooooXooXooX.OOO",
|
||||
"OOOXoo .. . ooXooXooX.OOO",
|
||||
"OOOXoooooooooooooooooXooXooX.OOO",
|
||||
"OOOXoooooooooooooooooXooXooX.OOO",
|
||||
"OOOXoo oooooooooXooXooX.OOO",
|
||||
"OOOXoooooooooooooooooXooXooX.OOO",
|
||||
"OOOXoooooooooooooooooXooXooX.OOO",
|
||||
"OOOXoo . ooooXooXooX.OOO",
|
||||
"OOOXoooooooooooooooooXooXooX.OOO",
|
||||
"OOOXoooooooooooooooooXooXooX.OOO",
|
||||
"OOOXoo . oooooXooXooX.OOO",
|
||||
"OOOXoooooooooooooooooXooXooX.OOO",
|
||||
"OOOXoooooooooooooooooXooXooX.OOO",
|
||||
"OOOXoo . . ooXooXooX.OOO",
|
||||
"OOOXoooooooooooooooooXooXXXX.OOO",
|
||||
"OOOXoooooooooooooooooXooX....OOO",
|
||||
"OOOXoo . . oXooX.OOOOOO",
|
||||
"OOOXoooooooooooooooooXXXX.OOOOOO",
|
||||
"OOOXoooooooooooooooooX....OOOOOO",
|
||||
"OOOXoooooooooooooooooX.OOOOOOOOO",
|
||||
"OOOXXXXXXXXXXXXXXXXXXX.OOOOOOOOO",
|
||||
"OOOOO..................OOOOOOOOO",
|
||||
"OOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOO"
|
||||
};
|
||||
19
libs/wxWidgets-3.3.1/samples/docview/docview.bkl
Normal file
19
libs/wxWidgets-3.3.1/samples/docview/docview.bkl
Normal file
@@ -0,0 +1,19 @@
|
||||
<?xml version="1.0" ?>
|
||||
<makefile>
|
||||
|
||||
<set var="BUNDLE_PLIST">$(SRCDIR)/Info.plist.in</set>
|
||||
<set var="BUNDLE_ICON">$(SRCDIR)/doc.icns</set>
|
||||
<set var="BUNDLE_RESOURCES">$(SRCDIR)/chart.icns $(SRCDIR)/notepad.icns</set>
|
||||
|
||||
<include file="../../build/bakefiles/common_samples.bkl"/>
|
||||
|
||||
<exe id="docview" template="wx_sample" template_append="wx_append">
|
||||
<sources>docview.cpp doc.cpp view.cpp</sources>
|
||||
<headers>docview.h doc.h view.h</headers>
|
||||
<wx-lib>aui</wx-lib>
|
||||
<wx-lib>core</wx-lib>
|
||||
<wx-lib>base</wx-lib>
|
||||
<win32-res>docview.rc</win32-res>
|
||||
</exe>
|
||||
|
||||
</makefile>
|
||||
493
libs/wxWidgets-3.3.1/samples/docview/docview.cpp
Normal file
493
libs/wxWidgets-3.3.1/samples/docview/docview.cpp
Normal file
@@ -0,0 +1,493 @@
|
||||
/////////////////////////////////////////////////////////////////////////////
|
||||
// Name: samples/docview/docview.cpp
|
||||
// Purpose: Document/view demo
|
||||
// Author: Julian Smart
|
||||
// Modified by: Vadim Zeitlin: merge with the MDI version and general cleanup
|
||||
// Created: 04/01/98
|
||||
// Copyright: (c) 1998 Julian Smart
|
||||
// (c) 2008 Vadim Zeitlin
|
||||
// Licence: wxWindows licence
|
||||
/////////////////////////////////////////////////////////////////////////////
|
||||
|
||||
/*
|
||||
This sample show document/view support in wxWidgets.
|
||||
|
||||
It can be run in several ways:
|
||||
* With "--mdi" command line option to use multiple MDI child frames
|
||||
for the multiple documents (this is the default).
|
||||
* With "--sdi" command line option to use multiple top level windows
|
||||
for the multiple documents
|
||||
* With "--single" command line option to support opening a single
|
||||
document only
|
||||
|
||||
Notice that doing it like this somewhat complicates the code, you could
|
||||
make things much simpler in your own programs by using either
|
||||
wxDocParentFrame or wxDocMDIParentFrame unconditionally (and never using
|
||||
the single mode) instead of supporting all of them as this sample does.
|
||||
*/
|
||||
|
||||
// ----------------------------------------------------------------------------
|
||||
// headers
|
||||
// ----------------------------------------------------------------------------
|
||||
|
||||
// For compilers that support precompilation, includes "wx/wx.h".
|
||||
#include "wx/wxprec.h"
|
||||
|
||||
|
||||
#ifndef WX_PRECOMP
|
||||
#include "wx/wx.h"
|
||||
#include "wx/stockitem.h"
|
||||
#endif
|
||||
|
||||
#if !wxUSE_DOC_VIEW_ARCHITECTURE
|
||||
#error You must set wxUSE_DOC_VIEW_ARCHITECTURE to 1 in setup.h!
|
||||
#endif
|
||||
|
||||
#include "wx/docview.h"
|
||||
#include "wx/docmdi.h"
|
||||
|
||||
#if wxUSE_AUI
|
||||
#include "wx/aui/tabmdi.h"
|
||||
#endif // wxUSE_AUI
|
||||
|
||||
#include "docview.h"
|
||||
#include "doc.h"
|
||||
#include "view.h"
|
||||
|
||||
#include "wx/cmdline.h"
|
||||
#include "wx/config.h"
|
||||
|
||||
#ifdef __WXMAC__
|
||||
#include "wx/filename.h"
|
||||
#endif
|
||||
|
||||
#ifndef wxHAS_IMAGES_IN_RESOURCES
|
||||
#include "doc.xpm"
|
||||
#include "chart.xpm"
|
||||
#include "notepad.xpm"
|
||||
#endif
|
||||
|
||||
// ----------------------------------------------------------------------------
|
||||
// MyApp implementation
|
||||
// ----------------------------------------------------------------------------
|
||||
|
||||
wxIMPLEMENT_APP(MyApp);
|
||||
|
||||
wxBEGIN_EVENT_TABLE(MyApp, wxApp)
|
||||
EVT_MENU(wxID_ABOUT, MyApp::OnAbout)
|
||||
EVT_MENU(wxID_CLEAR, MyApp::OnForceCloseAll)
|
||||
wxEND_EVENT_TABLE()
|
||||
|
||||
MyApp::MyApp()
|
||||
{
|
||||
#if wxUSE_MDI_ARCHITECTURE
|
||||
m_mode = Mode_MDI;
|
||||
#else
|
||||
m_mode = Mode_SDI;
|
||||
#endif
|
||||
|
||||
m_canvas = nullptr;
|
||||
m_menuEdit = nullptr;
|
||||
}
|
||||
|
||||
// constants for the command line options names
|
||||
namespace CmdLineOption
|
||||
{
|
||||
|
||||
#if wxUSE_MDI_ARCHITECTURE
|
||||
const char * const MDI = "mdi";
|
||||
#endif // wxUSE_MDI_ARCHITECTURE
|
||||
#if wxUSE_AUI
|
||||
const char * const AUI = "aui";
|
||||
#endif // wxUSE_AUI
|
||||
const char * const SDI = "sdi";
|
||||
const char * const SINGLE = "single";
|
||||
|
||||
} // namespace CmdLineOption
|
||||
|
||||
void MyApp::OnInitCmdLine(wxCmdLineParser& parser)
|
||||
{
|
||||
wxApp::OnInitCmdLine(parser);
|
||||
|
||||
#if wxUSE_MDI_ARCHITECTURE
|
||||
parser.AddSwitch("", CmdLineOption::MDI,
|
||||
"run in MDI mode: multiple documents, single window");
|
||||
#endif // wxUSE_MDI_ARCHITECTURE
|
||||
#if wxUSE_AUI
|
||||
parser.AddSwitch("", CmdLineOption::AUI,
|
||||
"run in MDI mode using AUI: multiple documents, single window");
|
||||
#endif // wxUSE_AUI
|
||||
parser.AddSwitch("", CmdLineOption::SDI,
|
||||
"run in SDI mode: multiple documents, multiple windows");
|
||||
parser.AddSwitch("", CmdLineOption::SINGLE,
|
||||
"run in single document mode");
|
||||
|
||||
parser.AddParam("document-file",
|
||||
wxCMD_LINE_VAL_STRING,
|
||||
wxCMD_LINE_PARAM_MULTIPLE | wxCMD_LINE_PARAM_OPTIONAL);
|
||||
}
|
||||
|
||||
bool MyApp::OnCmdLineParsed(wxCmdLineParser& parser)
|
||||
{
|
||||
int numModeOptions = 0;
|
||||
|
||||
#if wxUSE_MDI_ARCHITECTURE
|
||||
if ( parser.Found(CmdLineOption::MDI) )
|
||||
{
|
||||
m_mode = Mode_MDI;
|
||||
numModeOptions++;
|
||||
}
|
||||
#endif // wxUSE_MDI_ARCHITECTURE
|
||||
|
||||
#if wxUSE_AUI
|
||||
if ( parser.Found(CmdLineOption::AUI) )
|
||||
{
|
||||
m_mode = Mode_AUI;
|
||||
numModeOptions++;
|
||||
}
|
||||
#endif // wxUSE_AUI
|
||||
|
||||
if ( parser.Found(CmdLineOption::SDI) )
|
||||
{
|
||||
m_mode = Mode_SDI;
|
||||
numModeOptions++;
|
||||
}
|
||||
|
||||
if ( parser.Found(CmdLineOption::SINGLE) )
|
||||
{
|
||||
m_mode = Mode_Single;
|
||||
numModeOptions++;
|
||||
}
|
||||
|
||||
if ( numModeOptions > 1 )
|
||||
{
|
||||
wxLogError("Only a single option choosing the mode can be given.");
|
||||
return false;
|
||||
}
|
||||
|
||||
// save any files given on the command line: we'll open them in OnInit()
|
||||
// later, after creating the frame
|
||||
for ( size_t i = 0; i != parser.GetParamCount(); ++i )
|
||||
m_filesFromCmdLine.push_back(parser.GetParam(i));
|
||||
|
||||
return wxApp::OnCmdLineParsed(parser);
|
||||
}
|
||||
|
||||
#ifdef __WXMAC__
|
||||
void MyApp::MacNewFile()
|
||||
{
|
||||
wxDocManager::GetDocumentManager()->CreateNewDocument();
|
||||
}
|
||||
#endif // __WXMAC__
|
||||
|
||||
bool MyApp::OnInit()
|
||||
{
|
||||
if ( !wxApp::OnInit() )
|
||||
return false;
|
||||
|
||||
::wxInitAllImageHandlers();
|
||||
|
||||
// Fill in the application information fields before creating wxConfig.
|
||||
SetVendorName("wxWidgets_Samples");
|
||||
SetAppName("docview");
|
||||
SetAppDisplayName("wxWidgets DocView Sample");
|
||||
|
||||
//// Create a document manager
|
||||
wxDocManager *docManager = new wxDocManager;
|
||||
|
||||
//// Create a template relating drawing documents to their views
|
||||
new wxDocTemplate(docManager, "Drawing", "*.drw", "", "drw",
|
||||
"Drawing Doc", "Drawing View",
|
||||
CLASSINFO(DrawingDocument), CLASSINFO(DrawingView));
|
||||
|
||||
if ( m_mode == Mode_Single )
|
||||
{
|
||||
// If we've only got one window, we only get to edit one document at a
|
||||
// time. Therefore no text editing, just doodling.
|
||||
docManager->SetMaxDocsOpen(1);
|
||||
}
|
||||
else // multiple documents mode: allow documents of different types
|
||||
{
|
||||
// Create a template relating text documents to their views
|
||||
new wxDocTemplate(docManager, "Text", "*.txt;*.text", "", "txt;text",
|
||||
"Text Doc", "Text View",
|
||||
CLASSINFO(TextEditDocument), CLASSINFO(TextEditView));
|
||||
// Create a template relating image documents to their views
|
||||
new wxDocTemplate(docManager, "Image", "*.png;*.jpg", "", "png;jpg",
|
||||
"Image Doc", "Image View",
|
||||
CLASSINFO(ImageDocument), CLASSINFO(ImageView));
|
||||
}
|
||||
|
||||
// create the main frame window
|
||||
wxFrame *frame = nullptr;
|
||||
switch ( m_mode )
|
||||
{
|
||||
#if wxUSE_MDI_ARCHITECTURE
|
||||
case Mode_MDI:
|
||||
frame = new wxDocMDIParentFrame(docManager, nullptr, wxID_ANY,
|
||||
GetAppDisplayName(),
|
||||
wxDefaultPosition,
|
||||
wxSize(500, 400));
|
||||
break;
|
||||
#endif // wxUSE_MDI_ARCHITECTURE
|
||||
|
||||
#if wxUSE_AUI
|
||||
case Mode_AUI:
|
||||
frame = new wxDocParentFrameAny<wxAuiMDIParentFrame>
|
||||
(
|
||||
docManager, nullptr, wxID_ANY,
|
||||
GetAppDisplayName(),
|
||||
wxDefaultPosition,
|
||||
wxSize(500, 400)
|
||||
);
|
||||
break;
|
||||
#endif // wxUSE_AUI
|
||||
|
||||
case Mode_SDI:
|
||||
case Mode_Single:
|
||||
frame = new wxDocParentFrame(docManager, nullptr, wxID_ANY,
|
||||
GetAppDisplayName(),
|
||||
wxDefaultPosition,
|
||||
wxSize(500, 400));
|
||||
break;
|
||||
}
|
||||
|
||||
// and its menu bar
|
||||
wxMenu *menuFile = new wxMenu;
|
||||
|
||||
menuFile->Append(wxID_NEW);
|
||||
menuFile->Append(wxID_OPEN);
|
||||
|
||||
if ( m_mode == Mode_Single )
|
||||
AppendDocumentFileCommands(menuFile, true);
|
||||
|
||||
menuFile->AppendSeparator();
|
||||
menuFile->Append(wxID_EXIT);
|
||||
|
||||
// A nice touch: a history of files visited. Use this menu.
|
||||
docManager->FileHistoryUseMenu(menuFile);
|
||||
#if wxUSE_CONFIG
|
||||
docManager->FileHistoryLoad(*wxConfig::Get());
|
||||
#endif // wxUSE_CONFIG
|
||||
|
||||
|
||||
if ( m_mode == Mode_Single )
|
||||
{
|
||||
m_canvas = new MyCanvas(nullptr, frame);
|
||||
m_menuEdit = CreateDrawingEditMenu();
|
||||
}
|
||||
|
||||
CreateMenuBarForFrame(frame, menuFile, m_menuEdit);
|
||||
|
||||
frame->SetIcon(wxICON(doc));
|
||||
frame->Centre();
|
||||
frame->Show();
|
||||
|
||||
if ( m_filesFromCmdLine.empty() )
|
||||
{
|
||||
// on macOS the dialog will be shown by MacNewFile
|
||||
#ifndef __WXMAC__
|
||||
docManager->CreateNewDocument();
|
||||
#endif
|
||||
}
|
||||
else // we have files to open on command line
|
||||
{
|
||||
for ( size_t i = 0; i != m_filesFromCmdLine.size(); ++i )
|
||||
docManager->CreateDocument(m_filesFromCmdLine[i], wxDOC_SILENT);
|
||||
}
|
||||
|
||||
return true;
|
||||
}
|
||||
|
||||
int MyApp::OnExit()
|
||||
{
|
||||
wxDocManager * const manager = wxDocManager::GetDocumentManager();
|
||||
#if wxUSE_CONFIG
|
||||
manager->FileHistorySave(*wxConfig::Get());
|
||||
#endif // wxUSE_CONFIG
|
||||
delete manager;
|
||||
|
||||
return wxApp::OnExit();
|
||||
}
|
||||
|
||||
void MyApp::AppendDocumentFileCommands(wxMenu *menu, bool supportsPrinting)
|
||||
{
|
||||
menu->Append(wxID_CLOSE);
|
||||
menu->Append(wxID_SAVE);
|
||||
menu->Append(wxID_SAVEAS);
|
||||
menu->Append(wxID_REVERT, _("Re&vert..."));
|
||||
menu->Append(wxID_CLEAR, "&Force close all");
|
||||
|
||||
if ( supportsPrinting )
|
||||
{
|
||||
menu->AppendSeparator();
|
||||
menu->Append(wxID_PRINT);
|
||||
menu->Append(wxID_PRINT_SETUP, "Print &Setup...");
|
||||
menu->Append(wxID_PREVIEW);
|
||||
}
|
||||
}
|
||||
|
||||
wxMenu *MyApp::CreateDrawingEditMenu()
|
||||
{
|
||||
wxMenu * const menu = new wxMenu;
|
||||
menu->Append(wxID_UNDO);
|
||||
menu->Append(wxID_REDO);
|
||||
menu->AppendSeparator();
|
||||
menu->Append(wxID_CUT, "&Cut last segment");
|
||||
|
||||
return menu;
|
||||
}
|
||||
|
||||
void MyApp::CreateMenuBarForFrame(wxFrame *frame, wxMenu *file, wxMenu *edit)
|
||||
{
|
||||
wxMenuBar *menubar = new wxMenuBar;
|
||||
|
||||
menubar->Append(file, wxGetStockLabel(wxID_FILE));
|
||||
|
||||
if ( edit )
|
||||
menubar->Append(edit, wxGetStockLabel(wxID_EDIT));
|
||||
|
||||
wxMenu *help= new wxMenu;
|
||||
help->Append(wxID_ABOUT);
|
||||
menubar->Append(help, wxGetStockLabel(wxID_HELP));
|
||||
|
||||
frame->SetMenuBar(menubar);
|
||||
}
|
||||
|
||||
wxFrame *MyApp::CreateChildFrame(wxView *view, bool isCanvas)
|
||||
{
|
||||
// create a child frame of appropriate class for the current mode
|
||||
wxFrame *subframe = nullptr;
|
||||
wxDocument *doc = view->GetDocument();
|
||||
switch ( GetMode() )
|
||||
#if wxUSE_MDI_ARCHITECTURE
|
||||
{
|
||||
case Mode_MDI:
|
||||
subframe = new wxDocMDIChildFrame
|
||||
(
|
||||
doc,
|
||||
view,
|
||||
wxStaticCast(GetTopWindow(), wxDocMDIParentFrame),
|
||||
wxID_ANY,
|
||||
"Child Frame",
|
||||
wxDefaultPosition,
|
||||
wxSize(300, 300)
|
||||
);
|
||||
break;
|
||||
#endif // wxUSE_MDI_ARCHITECTURE
|
||||
|
||||
#if wxUSE_AUI
|
||||
case Mode_AUI:
|
||||
subframe = new wxDocChildFrameAny<wxAuiMDIChildFrame, wxAuiMDIParentFrame>
|
||||
(
|
||||
doc,
|
||||
view,
|
||||
wxStaticCast(GetTopWindow(), wxAuiMDIParentFrame),
|
||||
wxID_ANY,
|
||||
"Child Frame",
|
||||
wxDefaultPosition,
|
||||
wxSize(300, 300)
|
||||
);
|
||||
break;
|
||||
#endif // wxUSE_AUI
|
||||
|
||||
case Mode_SDI:
|
||||
case Mode_Single:
|
||||
subframe = new wxDocChildFrame
|
||||
(
|
||||
doc,
|
||||
view,
|
||||
wxStaticCast(GetTopWindow(), wxDocParentFrame),
|
||||
wxID_ANY,
|
||||
"Child Frame",
|
||||
wxDefaultPosition,
|
||||
wxSize(300, 300)
|
||||
);
|
||||
|
||||
subframe->Centre();
|
||||
break;
|
||||
}
|
||||
|
||||
wxMenu *menuFile = new wxMenu;
|
||||
|
||||
menuFile->Append(wxID_NEW);
|
||||
menuFile->Append(wxID_OPEN);
|
||||
AppendDocumentFileCommands(menuFile, isCanvas);
|
||||
menuFile->AppendSeparator();
|
||||
menuFile->Append(wxID_EXIT);
|
||||
|
||||
wxMenu *menuEdit;
|
||||
if ( isCanvas )
|
||||
{
|
||||
menuEdit = CreateDrawingEditMenu();
|
||||
|
||||
doc->GetCommandProcessor()->SetEditMenu(menuEdit);
|
||||
doc->GetCommandProcessor()->Initialize();
|
||||
}
|
||||
else // text frame
|
||||
{
|
||||
menuEdit = new wxMenu;
|
||||
menuEdit->Append(wxID_COPY);
|
||||
menuEdit->Append(wxID_PASTE);
|
||||
menuEdit->Append(wxID_SELECTALL);
|
||||
}
|
||||
|
||||
CreateMenuBarForFrame(subframe, menuFile, menuEdit);
|
||||
|
||||
subframe->SetIcon(isCanvas ? wxICON(chrt) : wxICON(notepad));
|
||||
|
||||
return subframe;
|
||||
}
|
||||
|
||||
void MyApp::OnForceCloseAll(wxCommandEvent& WXUNUSED(event))
|
||||
{
|
||||
// Pass "true" here to force closing just for testing this functionality,
|
||||
// there is no real reason to force the issue here.
|
||||
wxDocManager::GetDocumentManager()->CloseDocuments(true);
|
||||
}
|
||||
|
||||
void MyApp::OnAbout(wxCommandEvent& WXUNUSED(event))
|
||||
{
|
||||
wxString modeName;
|
||||
switch ( m_mode )
|
||||
{
|
||||
#if wxUSE_MDI_ARCHITECTURE
|
||||
case Mode_MDI:
|
||||
modeName = "MDI";
|
||||
break;
|
||||
#endif // wxUSE_MDI_ARCHITECTURE
|
||||
|
||||
#if wxUSE_AUI
|
||||
case Mode_AUI:
|
||||
modeName = "AUI";
|
||||
break;
|
||||
#endif // wxUSE_AUI
|
||||
|
||||
case Mode_SDI:
|
||||
modeName = "SDI";
|
||||
break;
|
||||
|
||||
case Mode_Single:
|
||||
modeName = "single document";
|
||||
break;
|
||||
|
||||
default:
|
||||
wxFAIL_MSG( "unknown mode ");
|
||||
}
|
||||
|
||||
const int docsCount =
|
||||
wxDocManager::GetDocumentManager()->GetDocumentsVector().size();
|
||||
|
||||
wxLogMessage
|
||||
(
|
||||
"This is the wxWidgets Document/View Sample\n"
|
||||
"running in %s mode.\n"
|
||||
"%d open documents.\n"
|
||||
"\n"
|
||||
"Authors: Julian Smart, Vadim Zeitlin\n"
|
||||
"\n"
|
||||
"Usage: docview [--{mdi,aui,sdi,single}]",
|
||||
modeName,
|
||||
docsCount
|
||||
);
|
||||
}
|
||||
99
libs/wxWidgets-3.3.1/samples/docview/docview.h
Normal file
99
libs/wxWidgets-3.3.1/samples/docview/docview.h
Normal file
@@ -0,0 +1,99 @@
|
||||
/////////////////////////////////////////////////////////////////////////////
|
||||
// Name: samples/docview/docview.h
|
||||
// Purpose: Document/view demo
|
||||
// Author: Julian Smart
|
||||
// Modified by: Vadim Zeitlin: merge with the MDI version and general cleanup
|
||||
// Created: 04/01/98
|
||||
// Copyright: (c) 1998 Julian Smart
|
||||
// (c) 2008 Vadim Zeitlin
|
||||
// Licence: wxWindows licence
|
||||
/////////////////////////////////////////////////////////////////////////////
|
||||
|
||||
#ifndef _WX_SAMPLES_DOCVIEW_DOCVIEW_H_
|
||||
#define _WX_SAMPLES_DOCVIEW_DOCVIEW_H_
|
||||
|
||||
#include "wx/docview.h"
|
||||
#include "wx/vector.h"
|
||||
|
||||
class MyCanvas;
|
||||
|
||||
// Define a new application
|
||||
class MyApp : public wxApp
|
||||
{
|
||||
public:
|
||||
// this sample can be launched in several different ways:
|
||||
enum Mode
|
||||
{
|
||||
#if wxUSE_MDI_ARCHITECTURE
|
||||
Mode_MDI, // MDI mode: multiple documents, single top level window
|
||||
#endif // wxUSE_MDI_ARCHITECTURE
|
||||
#if wxUSE_AUI
|
||||
Mode_AUI, // MDI AUI mode
|
||||
#endif // wxUSE_AUI
|
||||
Mode_SDI, // SDI mode: multiple documents, multiple top level windows
|
||||
Mode_Single // single document mode (and hence single top level window)
|
||||
};
|
||||
|
||||
MyApp();
|
||||
MyApp(const MyApp&) = delete;
|
||||
MyApp& operator=(const MyApp&) = delete;
|
||||
|
||||
// override some wxApp virtual methods
|
||||
virtual bool OnInit() override;
|
||||
virtual int OnExit() override;
|
||||
|
||||
virtual void OnInitCmdLine(wxCmdLineParser& parser) override;
|
||||
virtual bool OnCmdLineParsed(wxCmdLineParser& parser) override;
|
||||
|
||||
#ifdef __WXMAC__
|
||||
virtual void MacNewFile() override;
|
||||
#endif // __WXMAC__
|
||||
|
||||
// our specific methods
|
||||
Mode GetMode() const { return m_mode; }
|
||||
wxFrame *CreateChildFrame(wxView *view, bool isCanvas);
|
||||
|
||||
// these accessors should only be called in single document mode, otherwise
|
||||
// the pointers are null and an assert is triggered
|
||||
MyCanvas *GetMainWindowCanvas() const
|
||||
{ wxASSERT(m_canvas); return m_canvas; }
|
||||
wxMenu *GetMainWindowEditMenu() const
|
||||
{ wxASSERT(m_menuEdit); return m_menuEdit; }
|
||||
|
||||
private:
|
||||
// append the standard document-oriented menu commands to this menu
|
||||
void AppendDocumentFileCommands(wxMenu *menu, bool supportsPrinting);
|
||||
|
||||
// create the edit menu for drawing documents
|
||||
wxMenu *CreateDrawingEditMenu();
|
||||
|
||||
// create and associate with the given frame the menu bar containing the
|
||||
// given file and edit (possibly null) menus as well as the standard help
|
||||
// one
|
||||
void CreateMenuBarForFrame(wxFrame *frame, wxMenu *file, wxMenu *edit);
|
||||
|
||||
|
||||
// force close all windows
|
||||
void OnForceCloseAll(wxCommandEvent& event);
|
||||
|
||||
// show the about box: as we can have different frames it's more
|
||||
// convenient, even if somewhat less usual, to handle this in the
|
||||
// application object itself
|
||||
void OnAbout(wxCommandEvent& event);
|
||||
|
||||
// contains the file names given on the command line, possibly empty
|
||||
wxVector<wxString> m_filesFromCmdLine;
|
||||
|
||||
// the currently used mode
|
||||
Mode m_mode;
|
||||
|
||||
// only used if m_mode == Mode_Single
|
||||
MyCanvas *m_canvas;
|
||||
wxMenu *m_menuEdit;
|
||||
|
||||
wxDECLARE_EVENT_TABLE();
|
||||
};
|
||||
|
||||
wxDECLARE_APP(MyApp);
|
||||
|
||||
#endif // _WX_SAMPLES_DOCVIEW_DOCVIEW_H_
|
||||
6
libs/wxWidgets-3.3.1/samples/docview/docview.rc
Normal file
6
libs/wxWidgets-3.3.1/samples/docview/docview.rc
Normal file
@@ -0,0 +1,6 @@
|
||||
#include "../sample.rc"
|
||||
|
||||
doc ICON "doc.ico"
|
||||
chrt ICON "chart.ico"
|
||||
notepad ICON "notepad.ico"
|
||||
|
||||
452
libs/wxWidgets-3.3.1/samples/docview/docview.vcxproj
Normal file
452
libs/wxWidgets-3.3.1/samples/docview/docview.vcxproj
Normal file
@@ -0,0 +1,452 @@
|
||||
<?xml version="1.0" encoding="utf-8"?>
|
||||
<Project DefaultTargets="Build" ToolsVersion="4.0" xmlns="http://schemas.microsoft.com/developer/msbuild/2003">
|
||||
<ItemGroup Label="ProjectConfigurations">
|
||||
<ProjectConfiguration Include="Debug|Win32">
|
||||
<Configuration>Debug</Configuration>
|
||||
<Platform>Win32</Platform>
|
||||
</ProjectConfiguration>
|
||||
<ProjectConfiguration Include="Debug|x64">
|
||||
<Configuration>Debug</Configuration>
|
||||
<Platform>x64</Platform>
|
||||
</ProjectConfiguration>
|
||||
<ProjectConfiguration Include="DLL Debug|Win32">
|
||||
<Configuration>DLL Debug</Configuration>
|
||||
<Platform>Win32</Platform>
|
||||
</ProjectConfiguration>
|
||||
<ProjectConfiguration Include="DLL Debug|x64">
|
||||
<Configuration>DLL Debug</Configuration>
|
||||
<Platform>x64</Platform>
|
||||
</ProjectConfiguration>
|
||||
<ProjectConfiguration Include="DLL Release|Win32">
|
||||
<Configuration>DLL Release</Configuration>
|
||||
<Platform>Win32</Platform>
|
||||
</ProjectConfiguration>
|
||||
<ProjectConfiguration Include="DLL Release|x64">
|
||||
<Configuration>DLL Release</Configuration>
|
||||
<Platform>x64</Platform>
|
||||
</ProjectConfiguration>
|
||||
<ProjectConfiguration Include="Release|Win32">
|
||||
<Configuration>Release</Configuration>
|
||||
<Platform>Win32</Platform>
|
||||
</ProjectConfiguration>
|
||||
<ProjectConfiguration Include="Release|x64">
|
||||
<Configuration>Release</Configuration>
|
||||
<Platform>x64</Platform>
|
||||
</ProjectConfiguration>
|
||||
</ItemGroup>
|
||||
<PropertyGroup Label="Globals">
|
||||
<ProjectGuid>{CFBD4BEB-2F03-410A-BE37-F81D375682D3}</ProjectGuid>
|
||||
</PropertyGroup>
|
||||
<Import Project="..\..\build\msw\wx_config.props" />
|
||||
<Import Project="$(VCTargetsPath)\Microsoft.Cpp.Default.props" />
|
||||
<PropertyGroup Condition="'$(Configuration)|$(Platform)'=='DLL Release|Win32'" Label="Configuration">
|
||||
<ConfigurationType>Application</ConfigurationType>
|
||||
</PropertyGroup>
|
||||
<PropertyGroup Condition="'$(Configuration)|$(Platform)'=='DLL Debug|Win32'" Label="Configuration">
|
||||
<ConfigurationType>Application</ConfigurationType>
|
||||
</PropertyGroup>
|
||||
<PropertyGroup Condition="'$(Configuration)|$(Platform)'=='Release|Win32'" Label="Configuration">
|
||||
<ConfigurationType>Application</ConfigurationType>
|
||||
</PropertyGroup>
|
||||
<PropertyGroup Condition="'$(Configuration)|$(Platform)'=='Debug|Win32'" Label="Configuration">
|
||||
<ConfigurationType>Application</ConfigurationType>
|
||||
</PropertyGroup>
|
||||
<PropertyGroup Condition="'$(Configuration)|$(Platform)'=='DLL Release|x64'" Label="Configuration">
|
||||
<ConfigurationType>Application</ConfigurationType>
|
||||
</PropertyGroup>
|
||||
<PropertyGroup Condition="'$(Configuration)|$(Platform)'=='DLL Debug|x64'" Label="Configuration">
|
||||
<ConfigurationType>Application</ConfigurationType>
|
||||
</PropertyGroup>
|
||||
<PropertyGroup Condition="'$(Configuration)|$(Platform)'=='Release|x64'" Label="Configuration">
|
||||
<ConfigurationType>Application</ConfigurationType>
|
||||
</PropertyGroup>
|
||||
<PropertyGroup Condition="'$(Configuration)|$(Platform)'=='Debug|x64'" Label="Configuration">
|
||||
<ConfigurationType>Application</ConfigurationType>
|
||||
</PropertyGroup>
|
||||
<Import Project="$(VCTargetsPath)\Microsoft.Cpp.props" />
|
||||
<ImportGroup Label="ExtensionSettings">
|
||||
</ImportGroup>
|
||||
<ImportGroup Label="PropertySheets">
|
||||
<Import Project="..\..\build\msw\wx_setup.props" />
|
||||
<Import Project="..\..\build\msw\wx_local.props" Condition="Exists('..\..\build\msw\wx_local.props')" />
|
||||
<Import Project="..\samples.props" />
|
||||
</ImportGroup>
|
||||
<ImportGroup Condition="'$(Configuration)|$(Platform)'=='DLL Release|Win32'" Label="PropertySheets">
|
||||
<Import Project="$(UserRootDir)\Microsoft.Cpp.$(Platform).user.props" Condition="exists('$(UserRootDir)\Microsoft.Cpp.$(Platform).user.props')" Label="LocalAppDataPlatform" />
|
||||
</ImportGroup>
|
||||
<ImportGroup Condition="'$(Configuration)|$(Platform)'=='DLL Debug|Win32'" Label="PropertySheets">
|
||||
<Import Project="$(UserRootDir)\Microsoft.Cpp.$(Platform).user.props" Condition="exists('$(UserRootDir)\Microsoft.Cpp.$(Platform).user.props')" Label="LocalAppDataPlatform" />
|
||||
</ImportGroup>
|
||||
<ImportGroup Condition="'$(Configuration)|$(Platform)'=='Release|Win32'" Label="PropertySheets">
|
||||
<Import Project="$(UserRootDir)\Microsoft.Cpp.$(Platform).user.props" Condition="exists('$(UserRootDir)\Microsoft.Cpp.$(Platform).user.props')" Label="LocalAppDataPlatform" />
|
||||
</ImportGroup>
|
||||
<ImportGroup Condition="'$(Configuration)|$(Platform)'=='Debug|Win32'" Label="PropertySheets">
|
||||
<Import Project="$(UserRootDir)\Microsoft.Cpp.$(Platform).user.props" Condition="exists('$(UserRootDir)\Microsoft.Cpp.$(Platform).user.props')" Label="LocalAppDataPlatform" />
|
||||
</ImportGroup>
|
||||
<ImportGroup Condition="'$(Configuration)|$(Platform)'=='DLL Release|x64'" Label="PropertySheets">
|
||||
<Import Project="$(UserRootDir)\Microsoft.Cpp.$(Platform).user.props" Condition="exists('$(UserRootDir)\Microsoft.Cpp.$(Platform).user.props')" Label="LocalAppDataPlatform" />
|
||||
</ImportGroup>
|
||||
<ImportGroup Condition="'$(Configuration)|$(Platform)'=='DLL Debug|x64'" Label="PropertySheets">
|
||||
<Import Project="$(UserRootDir)\Microsoft.Cpp.$(Platform).user.props" Condition="exists('$(UserRootDir)\Microsoft.Cpp.$(Platform).user.props')" Label="LocalAppDataPlatform" />
|
||||
</ImportGroup>
|
||||
<ImportGroup Condition="'$(Configuration)|$(Platform)'=='Release|x64'" Label="PropertySheets">
|
||||
<Import Project="$(UserRootDir)\Microsoft.Cpp.$(Platform).user.props" Condition="exists('$(UserRootDir)\Microsoft.Cpp.$(Platform).user.props')" Label="LocalAppDataPlatform" />
|
||||
</ImportGroup>
|
||||
<ImportGroup Condition="'$(Configuration)|$(Platform)'=='Debug|x64'" Label="PropertySheets">
|
||||
<Import Project="$(UserRootDir)\Microsoft.Cpp.$(Platform).user.props" Condition="exists('$(UserRootDir)\Microsoft.Cpp.$(Platform).user.props')" Label="LocalAppDataPlatform" />
|
||||
</ImportGroup>
|
||||
<PropertyGroup Label="UserMacros" />
|
||||
<PropertyGroup>
|
||||
<_ProjectFileVersion>14.0.24720.0</_ProjectFileVersion>
|
||||
<OutDir>$(wxIntRootDir)</OutDir>
|
||||
<IntDir>$(wxIntRootDir)$(ProjectName)\</IntDir>
|
||||
<GenerateManifest>true</GenerateManifest>
|
||||
</PropertyGroup>
|
||||
<PropertyGroup Condition="'$(Configuration)|$(Platform)'=='Debug|Win32'">
|
||||
<LinkIncremental>true</LinkIncremental>
|
||||
</PropertyGroup>
|
||||
<PropertyGroup Condition="'$(Configuration)|$(Platform)'=='Release|Win32'">
|
||||
<LinkIncremental>false</LinkIncremental>
|
||||
</PropertyGroup>
|
||||
<PropertyGroup Condition="'$(Configuration)|$(Platform)'=='DLL Debug|Win32'">
|
||||
<LinkIncremental>true</LinkIncremental>
|
||||
</PropertyGroup>
|
||||
<PropertyGroup Condition="'$(Configuration)|$(Platform)'=='DLL Release|Win32'">
|
||||
<LinkIncremental>false</LinkIncremental>
|
||||
</PropertyGroup>
|
||||
<PropertyGroup Condition="'$(Configuration)|$(Platform)'=='Debug|x64'">
|
||||
<LinkIncremental>true</LinkIncremental>
|
||||
</PropertyGroup>
|
||||
<PropertyGroup Condition="'$(Configuration)|$(Platform)'=='Release|x64'">
|
||||
<LinkIncremental>false</LinkIncremental>
|
||||
</PropertyGroup>
|
||||
<PropertyGroup Condition="'$(Configuration)|$(Platform)'=='DLL Debug|x64'">
|
||||
<LinkIncremental>true</LinkIncremental>
|
||||
</PropertyGroup>
|
||||
<PropertyGroup Condition="'$(Configuration)|$(Platform)'=='DLL Release|x64'">
|
||||
<LinkIncremental>false</LinkIncremental>
|
||||
</PropertyGroup>
|
||||
<ItemDefinitionGroup Condition="'$(Configuration)|$(Platform)'=='Debug|Win32'">
|
||||
<Midl>
|
||||
<PreprocessorDefinitions>WIN32;_DEBUG;_CRT_SECURE_NO_DEPRECATE=1;_CRT_NON_CONFORMING_SWPRINTFS=1;_SCL_SECURE_NO_WARNINGS=1;__WXMSW__;_UNICODE;_WINDOWS;NOPCH;%(PreprocessorDefinitions)</PreprocessorDefinitions>
|
||||
<AdditionalIncludeDirectories>.\..\..\lib\$(wxOutDirName)\$(wxIncSubDir);.\..\..\include;.;.\..\..\samples;%(AdditionalIncludeDirectories)</AdditionalIncludeDirectories>
|
||||
</Midl>
|
||||
<ClCompile>
|
||||
<Optimization>Disabled</Optimization>
|
||||
<AdditionalIncludeDirectories>.\..\..\lib\$(wxOutDirName)\$(wxIncSubDir);.\..\..\include;.;.\..\..\samples;%(AdditionalIncludeDirectories)</AdditionalIncludeDirectories>
|
||||
<PreprocessorDefinitions>WIN32;_DEBUG;_CRT_SECURE_NO_DEPRECATE=1;_CRT_NON_CONFORMING_SWPRINTFS=1;_SCL_SECURE_NO_WARNINGS=1;__WXMSW__;_UNICODE;_WINDOWS;NOPCH;%(PreprocessorDefinitions)</PreprocessorDefinitions>
|
||||
<ExceptionHandling>Sync</ExceptionHandling>
|
||||
<BasicRuntimeChecks>EnableFastChecks</BasicRuntimeChecks>
|
||||
<RuntimeLibrary>MultiThreadedDebugDLL</RuntimeLibrary>
|
||||
<BufferSecurityCheck>true</BufferSecurityCheck>
|
||||
<RuntimeTypeInfo>true</RuntimeTypeInfo>
|
||||
<WarningLevel>Level4</WarningLevel>
|
||||
<SuppressStartupBanner>true</SuppressStartupBanner>
|
||||
<DebugInformationFormat>ProgramDatabase</DebugInformationFormat>
|
||||
<MultiProcessorCompilation>true</MultiProcessorCompilation>
|
||||
</ClCompile>
|
||||
<ResourceCompile>
|
||||
<PreprocessorDefinitions>_DEBUG;_CRT_SECURE_NO_DEPRECATE=1;_CRT_NON_CONFORMING_SWPRINTFS=1;_SCL_SECURE_NO_WARNINGS=1;__WXMSW__;_UNICODE;_WINDOWS;NOPCH;%(PreprocessorDefinitions)</PreprocessorDefinitions>
|
||||
<Culture>0x0409</Culture>
|
||||
<AdditionalIncludeDirectories>.\..\..\lib\$(wxOutDirName)\$(wxIncSubDir);.\..\..\include;.;.\..\..\samples;%(AdditionalIncludeDirectories)</AdditionalIncludeDirectories>
|
||||
</ResourceCompile>
|
||||
<Link>
|
||||
<AdditionalDependencies>$(wxToolkitLibNamePrefix)aui.lib;$(wxToolkitLibNamePrefix)core.lib;$(wxBaseLibNamePrefix).lib;wxtiff$(wxSuffixDebug).lib;wxjpeg$(wxSuffixDebug).lib;wxpng$(wxSuffixDebug).lib;wxwebp$(wxSuffixDebug).lib;wxzlib$(wxSuffixDebug).lib;wxregexu$(wxSuffixDebug).lib;wxexpat$(wxSuffixDebug).lib;%(AdditionalDependencies)</AdditionalDependencies>
|
||||
<SuppressStartupBanner>true</SuppressStartupBanner>
|
||||
<AdditionalLibraryDirectories>.\..\..\lib\$(wxOutDirName);%(AdditionalLibraryDirectories)</AdditionalLibraryDirectories>
|
||||
<GenerateDebugInformation>true</GenerateDebugInformation>
|
||||
<SubSystem>Windows</SubSystem>
|
||||
<TargetMachine>MachineX86</TargetMachine>
|
||||
</Link>
|
||||
<Bscmake>
|
||||
<SuppressStartupBanner>true</SuppressStartupBanner>
|
||||
</Bscmake>
|
||||
<Manifest>
|
||||
<AdditionalManifestFiles>./../../include/wx/msw/wx_dpi_aware_pmv2.manifest %(AdditionalManifestFiles)</AdditionalManifestFiles>
|
||||
</Manifest>
|
||||
</ItemDefinitionGroup>
|
||||
<ItemDefinitionGroup Condition="'$(Configuration)|$(Platform)'=='Release|Win32'">
|
||||
<Midl>
|
||||
<PreprocessorDefinitions>WIN32;_CRT_SECURE_NO_DEPRECATE=1;_CRT_NON_CONFORMING_SWPRINTFS=1;_SCL_SECURE_NO_WARNINGS=1;__WXMSW__;NDEBUG;_UNICODE;_WINDOWS;NOPCH;%(PreprocessorDefinitions)</PreprocessorDefinitions>
|
||||
<AdditionalIncludeDirectories>.\..\..\lib\$(wxOutDirName)\$(wxIncSubDir);.\..\..\include;.;.\..\..\samples;%(AdditionalIncludeDirectories)</AdditionalIncludeDirectories>
|
||||
</Midl>
|
||||
<ClCompile>
|
||||
<Optimization>MaxSpeed</Optimization>
|
||||
<AdditionalIncludeDirectories>.\..\..\lib\$(wxOutDirName)\$(wxIncSubDir);.\..\..\include;.;.\..\..\samples;%(AdditionalIncludeDirectories)</AdditionalIncludeDirectories>
|
||||
<PreprocessorDefinitions>WIN32;_CRT_SECURE_NO_DEPRECATE=1;_CRT_NON_CONFORMING_SWPRINTFS=1;_SCL_SECURE_NO_WARNINGS=1;__WXMSW__;NDEBUG;_UNICODE;_WINDOWS;NOPCH;%(PreprocessorDefinitions)</PreprocessorDefinitions>
|
||||
<ExceptionHandling>Sync</ExceptionHandling>
|
||||
<RuntimeLibrary>MultiThreadedDLL</RuntimeLibrary>
|
||||
<RuntimeTypeInfo>true</RuntimeTypeInfo>
|
||||
<WarningLevel>Level4</WarningLevel>
|
||||
<SuppressStartupBanner>true</SuppressStartupBanner>
|
||||
<DebugInformationFormat>ProgramDatabase</DebugInformationFormat>
|
||||
<MultiProcessorCompilation>true</MultiProcessorCompilation>
|
||||
</ClCompile>
|
||||
<ResourceCompile>
|
||||
<PreprocessorDefinitions>_CRT_SECURE_NO_DEPRECATE=1;_CRT_NON_CONFORMING_SWPRINTFS=1;_SCL_SECURE_NO_WARNINGS=1;__WXMSW__;NDEBUG;_UNICODE;_WINDOWS;NOPCH;%(PreprocessorDefinitions)</PreprocessorDefinitions>
|
||||
<Culture>0x0409</Culture>
|
||||
<AdditionalIncludeDirectories>.\..\..\lib\$(wxOutDirName)\$(wxIncSubDir);.\..\..\include;.;.\..\..\samples;%(AdditionalIncludeDirectories)</AdditionalIncludeDirectories>
|
||||
</ResourceCompile>
|
||||
<Link>
|
||||
<AdditionalDependencies>$(wxToolkitLibNamePrefix)aui.lib;$(wxToolkitLibNamePrefix)core.lib;$(wxBaseLibNamePrefix).lib;wxtiff$(wxSuffixDebug).lib;wxjpeg$(wxSuffixDebug).lib;wxpng$(wxSuffixDebug).lib;wxwebp$(wxSuffixDebug).lib;wxzlib$(wxSuffixDebug).lib;wxregexu$(wxSuffixDebug).lib;wxexpat$(wxSuffixDebug).lib;%(AdditionalDependencies)</AdditionalDependencies>
|
||||
<SuppressStartupBanner>true</SuppressStartupBanner>
|
||||
<AdditionalLibraryDirectories>.\..\..\lib\$(wxOutDirName);%(AdditionalLibraryDirectories)</AdditionalLibraryDirectories>
|
||||
<GenerateDebugInformation>true</GenerateDebugInformation>
|
||||
<SubSystem>Windows</SubSystem>
|
||||
<TargetMachine>MachineX86</TargetMachine>
|
||||
<OptimizeReferences>true</OptimizeReferences>
|
||||
<EnableCOMDATFolding>true</EnableCOMDATFolding>
|
||||
</Link>
|
||||
<Bscmake>
|
||||
<SuppressStartupBanner>true</SuppressStartupBanner>
|
||||
</Bscmake>
|
||||
<Manifest>
|
||||
<AdditionalManifestFiles>./../../include/wx/msw/wx_dpi_aware_pmv2.manifest %(AdditionalManifestFiles)</AdditionalManifestFiles>
|
||||
</Manifest>
|
||||
</ItemDefinitionGroup>
|
||||
<ItemDefinitionGroup Condition="'$(Configuration)|$(Platform)'=='DLL Debug|Win32'">
|
||||
<Midl>
|
||||
<PreprocessorDefinitions>WIN32;_DEBUG;_CRT_SECURE_NO_DEPRECATE=1;_CRT_NON_CONFORMING_SWPRINTFS=1;_SCL_SECURE_NO_WARNINGS=1;__WXMSW__;_UNICODE;WXUSINGDLL;_WINDOWS;NOPCH;%(PreprocessorDefinitions)</PreprocessorDefinitions>
|
||||
<AdditionalIncludeDirectories>.\..\..\lib\$(wxOutDirName)\$(wxIncSubDir);.\..\..\include;.;.\..\..\samples;%(AdditionalIncludeDirectories)</AdditionalIncludeDirectories>
|
||||
</Midl>
|
||||
<ClCompile>
|
||||
<Optimization>Disabled</Optimization>
|
||||
<AdditionalIncludeDirectories>.\..\..\lib\$(wxOutDirName)\$(wxIncSubDir);.\..\..\include;.;.\..\..\samples;%(AdditionalIncludeDirectories)</AdditionalIncludeDirectories>
|
||||
<PreprocessorDefinitions>WIN32;_DEBUG;_CRT_SECURE_NO_DEPRECATE=1;_CRT_NON_CONFORMING_SWPRINTFS=1;_SCL_SECURE_NO_WARNINGS=1;__WXMSW__;_UNICODE;WXUSINGDLL;_WINDOWS;NOPCH;%(PreprocessorDefinitions)</PreprocessorDefinitions>
|
||||
<ExceptionHandling>Sync</ExceptionHandling>
|
||||
<BasicRuntimeChecks>EnableFastChecks</BasicRuntimeChecks>
|
||||
<RuntimeLibrary>MultiThreadedDebugDLL</RuntimeLibrary>
|
||||
<BufferSecurityCheck>true</BufferSecurityCheck>
|
||||
<RuntimeTypeInfo>true</RuntimeTypeInfo>
|
||||
<WarningLevel>Level4</WarningLevel>
|
||||
<SuppressStartupBanner>true</SuppressStartupBanner>
|
||||
<DebugInformationFormat>ProgramDatabase</DebugInformationFormat>
|
||||
<MultiProcessorCompilation>true</MultiProcessorCompilation>
|
||||
</ClCompile>
|
||||
<ResourceCompile>
|
||||
<PreprocessorDefinitions>_DEBUG;_CRT_SECURE_NO_DEPRECATE=1;_CRT_NON_CONFORMING_SWPRINTFS=1;_SCL_SECURE_NO_WARNINGS=1;__WXMSW__;_UNICODE;WXUSINGDLL;_WINDOWS;NOPCH;%(PreprocessorDefinitions)</PreprocessorDefinitions>
|
||||
<Culture>0x0409</Culture>
|
||||
<AdditionalIncludeDirectories>.\..\..\lib\$(wxOutDirName)\$(wxIncSubDir);.\..\..\include;.;.\..\..\samples;%(AdditionalIncludeDirectories)</AdditionalIncludeDirectories>
|
||||
</ResourceCompile>
|
||||
<Link>
|
||||
<AdditionalDependencies>$(wxToolkitLibNamePrefix)aui.lib;$(wxToolkitLibNamePrefix)core.lib;$(wxBaseLibNamePrefix).lib;wxtiff$(wxSuffixDebug).lib;wxjpeg$(wxSuffixDebug).lib;wxpng$(wxSuffixDebug).lib;wxwebp$(wxSuffixDebug).lib;wxzlib$(wxSuffixDebug).lib;wxregexu$(wxSuffixDebug).lib;wxexpat$(wxSuffixDebug).lib;%(AdditionalDependencies)</AdditionalDependencies>
|
||||
<SuppressStartupBanner>true</SuppressStartupBanner>
|
||||
<AdditionalLibraryDirectories>.\..\..\lib\$(wxOutDirName);%(AdditionalLibraryDirectories)</AdditionalLibraryDirectories>
|
||||
<GenerateDebugInformation>true</GenerateDebugInformation>
|
||||
<SubSystem>Windows</SubSystem>
|
||||
<TargetMachine>MachineX86</TargetMachine>
|
||||
</Link>
|
||||
<Bscmake>
|
||||
<SuppressStartupBanner>true</SuppressStartupBanner>
|
||||
</Bscmake>
|
||||
<Manifest>
|
||||
<AdditionalManifestFiles>./../../include/wx/msw/wx_dpi_aware_pmv2.manifest %(AdditionalManifestFiles)</AdditionalManifestFiles>
|
||||
</Manifest>
|
||||
</ItemDefinitionGroup>
|
||||
<ItemDefinitionGroup Condition="'$(Configuration)|$(Platform)'=='DLL Release|Win32'">
|
||||
<Midl>
|
||||
<PreprocessorDefinitions>WIN32;_CRT_SECURE_NO_DEPRECATE=1;_CRT_NON_CONFORMING_SWPRINTFS=1;_SCL_SECURE_NO_WARNINGS=1;__WXMSW__;NDEBUG;_UNICODE;WXUSINGDLL;_WINDOWS;NOPCH;%(PreprocessorDefinitions)</PreprocessorDefinitions>
|
||||
<AdditionalIncludeDirectories>.\..\..\lib\$(wxOutDirName)\$(wxIncSubDir);.\..\..\include;.;.\..\..\samples;%(AdditionalIncludeDirectories)</AdditionalIncludeDirectories>
|
||||
</Midl>
|
||||
<ClCompile>
|
||||
<Optimization>MaxSpeed</Optimization>
|
||||
<AdditionalIncludeDirectories>.\..\..\lib\$(wxOutDirName)\$(wxIncSubDir);.\..\..\include;.;.\..\..\samples;%(AdditionalIncludeDirectories)</AdditionalIncludeDirectories>
|
||||
<PreprocessorDefinitions>WIN32;_CRT_SECURE_NO_DEPRECATE=1;_CRT_NON_CONFORMING_SWPRINTFS=1;_SCL_SECURE_NO_WARNINGS=1;__WXMSW__;NDEBUG;_UNICODE;WXUSINGDLL;_WINDOWS;NOPCH;%(PreprocessorDefinitions)</PreprocessorDefinitions>
|
||||
<ExceptionHandling>Sync</ExceptionHandling>
|
||||
<RuntimeLibrary>MultiThreadedDLL</RuntimeLibrary>
|
||||
<RuntimeTypeInfo>true</RuntimeTypeInfo>
|
||||
<WarningLevel>Level4</WarningLevel>
|
||||
<SuppressStartupBanner>true</SuppressStartupBanner>
|
||||
<DebugInformationFormat>ProgramDatabase</DebugInformationFormat>
|
||||
<MultiProcessorCompilation>true</MultiProcessorCompilation>
|
||||
</ClCompile>
|
||||
<ResourceCompile>
|
||||
<PreprocessorDefinitions>_CRT_SECURE_NO_DEPRECATE=1;_CRT_NON_CONFORMING_SWPRINTFS=1;_SCL_SECURE_NO_WARNINGS=1;__WXMSW__;NDEBUG;_UNICODE;WXUSINGDLL;_WINDOWS;NOPCH;%(PreprocessorDefinitions)</PreprocessorDefinitions>
|
||||
<Culture>0x0409</Culture>
|
||||
<AdditionalIncludeDirectories>.\..\..\lib\$(wxOutDirName)\$(wxIncSubDir);.\..\..\include;.;.\..\..\samples;%(AdditionalIncludeDirectories)</AdditionalIncludeDirectories>
|
||||
</ResourceCompile>
|
||||
<Link>
|
||||
<AdditionalDependencies>$(wxToolkitLibNamePrefix)aui.lib;$(wxToolkitLibNamePrefix)core.lib;$(wxBaseLibNamePrefix).lib;wxtiff$(wxSuffixDebug).lib;wxjpeg$(wxSuffixDebug).lib;wxpng$(wxSuffixDebug).lib;wxwebp$(wxSuffixDebug).lib;wxzlib$(wxSuffixDebug).lib;wxregexu$(wxSuffixDebug).lib;wxexpat$(wxSuffixDebug).lib;%(AdditionalDependencies)</AdditionalDependencies>
|
||||
<SuppressStartupBanner>true</SuppressStartupBanner>
|
||||
<AdditionalLibraryDirectories>.\..\..\lib\$(wxOutDirName);%(AdditionalLibraryDirectories)</AdditionalLibraryDirectories>
|
||||
<GenerateDebugInformation>true</GenerateDebugInformation>
|
||||
<SubSystem>Windows</SubSystem>
|
||||
<TargetMachine>MachineX86</TargetMachine>
|
||||
<OptimizeReferences>true</OptimizeReferences>
|
||||
<EnableCOMDATFolding>true</EnableCOMDATFolding>
|
||||
</Link>
|
||||
<Bscmake>
|
||||
<SuppressStartupBanner>true</SuppressStartupBanner>
|
||||
</Bscmake>
|
||||
<Manifest>
|
||||
<AdditionalManifestFiles>./../../include/wx/msw/wx_dpi_aware_pmv2.manifest %(AdditionalManifestFiles)</AdditionalManifestFiles>
|
||||
</Manifest>
|
||||
</ItemDefinitionGroup>
|
||||
<ItemDefinitionGroup Condition="'$(Configuration)|$(Platform)'=='Debug|x64'">
|
||||
<Midl>
|
||||
<PreprocessorDefinitions>WIN32;_DEBUG;_CRT_SECURE_NO_DEPRECATE=1;_CRT_NON_CONFORMING_SWPRINTFS=1;_SCL_SECURE_NO_WARNINGS=1;__WXMSW__;_UNICODE;_WINDOWS;NOPCH;%(PreprocessorDefinitions)</PreprocessorDefinitions>
|
||||
<AdditionalIncludeDirectories>.\..\..\lib\$(wxOutDirName)\$(wxIncSubDir);.\..\..\include;.;.\..\..\samples;%(AdditionalIncludeDirectories)</AdditionalIncludeDirectories>
|
||||
</Midl>
|
||||
<ClCompile>
|
||||
<Optimization>Disabled</Optimization>
|
||||
<AdditionalIncludeDirectories>.\..\..\lib\$(wxOutDirName)\$(wxIncSubDir);.\..\..\include;.;.\..\..\samples;%(AdditionalIncludeDirectories)</AdditionalIncludeDirectories>
|
||||
<PreprocessorDefinitions>WIN32;_DEBUG;_CRT_SECURE_NO_DEPRECATE=1;_CRT_NON_CONFORMING_SWPRINTFS=1;_SCL_SECURE_NO_WARNINGS=1;__WXMSW__;_UNICODE;_WINDOWS;NOPCH;%(PreprocessorDefinitions)</PreprocessorDefinitions>
|
||||
<ExceptionHandling>Sync</ExceptionHandling>
|
||||
<BasicRuntimeChecks>EnableFastChecks</BasicRuntimeChecks>
|
||||
<RuntimeLibrary>MultiThreadedDebugDLL</RuntimeLibrary>
|
||||
<BufferSecurityCheck>true</BufferSecurityCheck>
|
||||
<RuntimeTypeInfo>true</RuntimeTypeInfo>
|
||||
<WarningLevel>Level4</WarningLevel>
|
||||
<SuppressStartupBanner>true</SuppressStartupBanner>
|
||||
<DebugInformationFormat>ProgramDatabase</DebugInformationFormat>
|
||||
<MultiProcessorCompilation>true</MultiProcessorCompilation>
|
||||
</ClCompile>
|
||||
<ResourceCompile>
|
||||
<PreprocessorDefinitions>_DEBUG;_CRT_SECURE_NO_DEPRECATE=1;_CRT_NON_CONFORMING_SWPRINTFS=1;_SCL_SECURE_NO_WARNINGS=1;__WXMSW__;_UNICODE;_WINDOWS;NOPCH;%(PreprocessorDefinitions)</PreprocessorDefinitions>
|
||||
<Culture>0x0409</Culture>
|
||||
<AdditionalIncludeDirectories>.\..\..\lib\$(wxOutDirName)\$(wxIncSubDir);.\..\..\include;.;.\..\..\samples;%(AdditionalIncludeDirectories)</AdditionalIncludeDirectories>
|
||||
</ResourceCompile>
|
||||
<Link>
|
||||
<AdditionalDependencies>$(wxToolkitLibNamePrefix)aui.lib;$(wxToolkitLibNamePrefix)core.lib;$(wxBaseLibNamePrefix).lib;wxtiff$(wxSuffixDebug).lib;wxjpeg$(wxSuffixDebug).lib;wxpng$(wxSuffixDebug).lib;wxwebp$(wxSuffixDebug).lib;wxzlib$(wxSuffixDebug).lib;wxregexu$(wxSuffixDebug).lib;wxexpat$(wxSuffixDebug).lib;%(AdditionalDependencies)</AdditionalDependencies>
|
||||
<SuppressStartupBanner>true</SuppressStartupBanner>
|
||||
<AdditionalLibraryDirectories>.\..\..\lib\$(wxOutDirName);%(AdditionalLibraryDirectories)</AdditionalLibraryDirectories>
|
||||
<GenerateDebugInformation>true</GenerateDebugInformation>
|
||||
<SubSystem>Windows</SubSystem>
|
||||
<TargetMachine>MachineX64</TargetMachine>
|
||||
</Link>
|
||||
<Bscmake>
|
||||
<SuppressStartupBanner>true</SuppressStartupBanner>
|
||||
</Bscmake>
|
||||
<Manifest>
|
||||
<AdditionalManifestFiles>./../../include/wx/msw/wx_dpi_aware_pmv2.manifest %(AdditionalManifestFiles)</AdditionalManifestFiles>
|
||||
</Manifest>
|
||||
</ItemDefinitionGroup>
|
||||
<ItemDefinitionGroup Condition="'$(Configuration)|$(Platform)'=='Release|x64'">
|
||||
<Midl>
|
||||
<PreprocessorDefinitions>WIN32;_CRT_SECURE_NO_DEPRECATE=1;_CRT_NON_CONFORMING_SWPRINTFS=1;_SCL_SECURE_NO_WARNINGS=1;__WXMSW__;NDEBUG;_UNICODE;_WINDOWS;NOPCH;%(PreprocessorDefinitions)</PreprocessorDefinitions>
|
||||
<AdditionalIncludeDirectories>.\..\..\lib\$(wxOutDirName)\$(wxIncSubDir);.\..\..\include;.;.\..\..\samples;%(AdditionalIncludeDirectories)</AdditionalIncludeDirectories>
|
||||
</Midl>
|
||||
<ClCompile>
|
||||
<Optimization>MaxSpeed</Optimization>
|
||||
<AdditionalIncludeDirectories>.\..\..\lib\$(wxOutDirName)\$(wxIncSubDir);.\..\..\include;.;.\..\..\samples;%(AdditionalIncludeDirectories)</AdditionalIncludeDirectories>
|
||||
<PreprocessorDefinitions>WIN32;_CRT_SECURE_NO_DEPRECATE=1;_CRT_NON_CONFORMING_SWPRINTFS=1;_SCL_SECURE_NO_WARNINGS=1;__WXMSW__;NDEBUG;_UNICODE;_WINDOWS;NOPCH;%(PreprocessorDefinitions)</PreprocessorDefinitions>
|
||||
<ExceptionHandling>Sync</ExceptionHandling>
|
||||
<RuntimeLibrary>MultiThreadedDLL</RuntimeLibrary>
|
||||
<RuntimeTypeInfo>true</RuntimeTypeInfo>
|
||||
<WarningLevel>Level4</WarningLevel>
|
||||
<SuppressStartupBanner>true</SuppressStartupBanner>
|
||||
<DebugInformationFormat>ProgramDatabase</DebugInformationFormat>
|
||||
<MultiProcessorCompilation>true</MultiProcessorCompilation>
|
||||
</ClCompile>
|
||||
<ResourceCompile>
|
||||
<PreprocessorDefinitions>_CRT_SECURE_NO_DEPRECATE=1;_CRT_NON_CONFORMING_SWPRINTFS=1;_SCL_SECURE_NO_WARNINGS=1;__WXMSW__;NDEBUG;_UNICODE;_WINDOWS;NOPCH;%(PreprocessorDefinitions)</PreprocessorDefinitions>
|
||||
<Culture>0x0409</Culture>
|
||||
<AdditionalIncludeDirectories>.\..\..\lib\$(wxOutDirName)\$(wxIncSubDir);.\..\..\include;.;.\..\..\samples;%(AdditionalIncludeDirectories)</AdditionalIncludeDirectories>
|
||||
</ResourceCompile>
|
||||
<Link>
|
||||
<AdditionalDependencies>$(wxToolkitLibNamePrefix)aui.lib;$(wxToolkitLibNamePrefix)core.lib;$(wxBaseLibNamePrefix).lib;wxtiff$(wxSuffixDebug).lib;wxjpeg$(wxSuffixDebug).lib;wxpng$(wxSuffixDebug).lib;wxwebp$(wxSuffixDebug).lib;wxzlib$(wxSuffixDebug).lib;wxregexu$(wxSuffixDebug).lib;wxexpat$(wxSuffixDebug).lib;%(AdditionalDependencies)</AdditionalDependencies>
|
||||
<SuppressStartupBanner>true</SuppressStartupBanner>
|
||||
<AdditionalLibraryDirectories>.\..\..\lib\$(wxOutDirName);%(AdditionalLibraryDirectories)</AdditionalLibraryDirectories>
|
||||
<GenerateDebugInformation>true</GenerateDebugInformation>
|
||||
<SubSystem>Windows</SubSystem>
|
||||
<TargetMachine>MachineX64</TargetMachine>
|
||||
<OptimizeReferences>true</OptimizeReferences>
|
||||
<EnableCOMDATFolding>true</EnableCOMDATFolding>
|
||||
</Link>
|
||||
<Bscmake>
|
||||
<SuppressStartupBanner>true</SuppressStartupBanner>
|
||||
</Bscmake>
|
||||
<Manifest>
|
||||
<AdditionalManifestFiles>./../../include/wx/msw/wx_dpi_aware_pmv2.manifest %(AdditionalManifestFiles)</AdditionalManifestFiles>
|
||||
</Manifest>
|
||||
</ItemDefinitionGroup>
|
||||
<ItemDefinitionGroup Condition="'$(Configuration)|$(Platform)'=='DLL Debug|x64'">
|
||||
<Midl>
|
||||
<PreprocessorDefinitions>WIN32;_DEBUG;_CRT_SECURE_NO_DEPRECATE=1;_CRT_NON_CONFORMING_SWPRINTFS=1;_SCL_SECURE_NO_WARNINGS=1;__WXMSW__;_UNICODE;WXUSINGDLL;_WINDOWS;NOPCH;%(PreprocessorDefinitions)</PreprocessorDefinitions>
|
||||
<AdditionalIncludeDirectories>.\..\..\lib\$(wxOutDirName)\$(wxIncSubDir);.\..\..\include;.;.\..\..\samples;%(AdditionalIncludeDirectories)</AdditionalIncludeDirectories>
|
||||
</Midl>
|
||||
<ClCompile>
|
||||
<Optimization>Disabled</Optimization>
|
||||
<AdditionalIncludeDirectories>.\..\..\lib\$(wxOutDirName)\$(wxIncSubDir);.\..\..\include;.;.\..\..\samples;%(AdditionalIncludeDirectories)</AdditionalIncludeDirectories>
|
||||
<PreprocessorDefinitions>WIN32;_DEBUG;_CRT_SECURE_NO_DEPRECATE=1;_CRT_NON_CONFORMING_SWPRINTFS=1;_SCL_SECURE_NO_WARNINGS=1;__WXMSW__;_UNICODE;WXUSINGDLL;_WINDOWS;NOPCH;%(PreprocessorDefinitions)</PreprocessorDefinitions>
|
||||
<ExceptionHandling>Sync</ExceptionHandling>
|
||||
<BasicRuntimeChecks>EnableFastChecks</BasicRuntimeChecks>
|
||||
<RuntimeLibrary>MultiThreadedDebugDLL</RuntimeLibrary>
|
||||
<BufferSecurityCheck>true</BufferSecurityCheck>
|
||||
<RuntimeTypeInfo>true</RuntimeTypeInfo>
|
||||
<WarningLevel>Level4</WarningLevel>
|
||||
<SuppressStartupBanner>true</SuppressStartupBanner>
|
||||
<DebugInformationFormat>ProgramDatabase</DebugInformationFormat>
|
||||
<MultiProcessorCompilation>true</MultiProcessorCompilation>
|
||||
</ClCompile>
|
||||
<ResourceCompile>
|
||||
<PreprocessorDefinitions>_DEBUG;_CRT_SECURE_NO_DEPRECATE=1;_CRT_NON_CONFORMING_SWPRINTFS=1;_SCL_SECURE_NO_WARNINGS=1;__WXMSW__;_UNICODE;WXUSINGDLL;_WINDOWS;NOPCH;%(PreprocessorDefinitions)</PreprocessorDefinitions>
|
||||
<Culture>0x0409</Culture>
|
||||
<AdditionalIncludeDirectories>.\..\..\lib\$(wxOutDirName)\$(wxIncSubDir);.\..\..\include;.;.\..\..\samples;%(AdditionalIncludeDirectories)</AdditionalIncludeDirectories>
|
||||
</ResourceCompile>
|
||||
<Link>
|
||||
<AdditionalDependencies>$(wxToolkitLibNamePrefix)aui.lib;$(wxToolkitLibNamePrefix)core.lib;$(wxBaseLibNamePrefix).lib;wxtiff$(wxSuffixDebug).lib;wxjpeg$(wxSuffixDebug).lib;wxpng$(wxSuffixDebug).lib;wxwebp$(wxSuffixDebug).lib;wxzlib$(wxSuffixDebug).lib;wxregexu$(wxSuffixDebug).lib;wxexpat$(wxSuffixDebug).lib;%(AdditionalDependencies)</AdditionalDependencies>
|
||||
<SuppressStartupBanner>true</SuppressStartupBanner>
|
||||
<AdditionalLibraryDirectories>.\..\..\lib\$(wxOutDirName);%(AdditionalLibraryDirectories)</AdditionalLibraryDirectories>
|
||||
<GenerateDebugInformation>true</GenerateDebugInformation>
|
||||
<SubSystem>Windows</SubSystem>
|
||||
<TargetMachine>MachineX64</TargetMachine>
|
||||
</Link>
|
||||
<Bscmake>
|
||||
<SuppressStartupBanner>true</SuppressStartupBanner>
|
||||
</Bscmake>
|
||||
<Manifest>
|
||||
<AdditionalManifestFiles>./../../include/wx/msw/wx_dpi_aware_pmv2.manifest %(AdditionalManifestFiles)</AdditionalManifestFiles>
|
||||
</Manifest>
|
||||
</ItemDefinitionGroup>
|
||||
<ItemDefinitionGroup Condition="'$(Configuration)|$(Platform)'=='DLL Release|x64'">
|
||||
<Midl>
|
||||
<PreprocessorDefinitions>WIN32;_CRT_SECURE_NO_DEPRECATE=1;_CRT_NON_CONFORMING_SWPRINTFS=1;_SCL_SECURE_NO_WARNINGS=1;__WXMSW__;NDEBUG;_UNICODE;WXUSINGDLL;_WINDOWS;NOPCH;%(PreprocessorDefinitions)</PreprocessorDefinitions>
|
||||
<AdditionalIncludeDirectories>.\..\..\lib\$(wxOutDirName)\$(wxIncSubDir);.\..\..\include;.;.\..\..\samples;%(AdditionalIncludeDirectories)</AdditionalIncludeDirectories>
|
||||
</Midl>
|
||||
<ClCompile>
|
||||
<Optimization>MaxSpeed</Optimization>
|
||||
<AdditionalIncludeDirectories>.\..\..\lib\$(wxOutDirName)\$(wxIncSubDir);.\..\..\include;.;.\..\..\samples;%(AdditionalIncludeDirectories)</AdditionalIncludeDirectories>
|
||||
<PreprocessorDefinitions>WIN32;_CRT_SECURE_NO_DEPRECATE=1;_CRT_NON_CONFORMING_SWPRINTFS=1;_SCL_SECURE_NO_WARNINGS=1;__WXMSW__;NDEBUG;_UNICODE;WXUSINGDLL;_WINDOWS;NOPCH;%(PreprocessorDefinitions)</PreprocessorDefinitions>
|
||||
<ExceptionHandling>Sync</ExceptionHandling>
|
||||
<RuntimeLibrary>MultiThreadedDLL</RuntimeLibrary>
|
||||
<RuntimeTypeInfo>true</RuntimeTypeInfo>
|
||||
<WarningLevel>Level4</WarningLevel>
|
||||
<SuppressStartupBanner>true</SuppressStartupBanner>
|
||||
<DebugInformationFormat>ProgramDatabase</DebugInformationFormat>
|
||||
<MultiProcessorCompilation>true</MultiProcessorCompilation>
|
||||
</ClCompile>
|
||||
<ResourceCompile>
|
||||
<PreprocessorDefinitions>_CRT_SECURE_NO_DEPRECATE=1;_CRT_NON_CONFORMING_SWPRINTFS=1;_SCL_SECURE_NO_WARNINGS=1;__WXMSW__;NDEBUG;_UNICODE;WXUSINGDLL;_WINDOWS;NOPCH;%(PreprocessorDefinitions)</PreprocessorDefinitions>
|
||||
<Culture>0x0409</Culture>
|
||||
<AdditionalIncludeDirectories>.\..\..\lib\$(wxOutDirName)\$(wxIncSubDir);.\..\..\include;.;.\..\..\samples;%(AdditionalIncludeDirectories)</AdditionalIncludeDirectories>
|
||||
</ResourceCompile>
|
||||
<Link>
|
||||
<AdditionalDependencies>$(wxToolkitLibNamePrefix)aui.lib;$(wxToolkitLibNamePrefix)core.lib;$(wxBaseLibNamePrefix).lib;wxtiff$(wxSuffixDebug).lib;wxjpeg$(wxSuffixDebug).lib;wxpng$(wxSuffixDebug).lib;wxwebp$(wxSuffixDebug).lib;wxzlib$(wxSuffixDebug).lib;wxregexu$(wxSuffixDebug).lib;wxexpat$(wxSuffixDebug).lib;%(AdditionalDependencies)</AdditionalDependencies>
|
||||
<SuppressStartupBanner>true</SuppressStartupBanner>
|
||||
<AdditionalLibraryDirectories>.\..\..\lib\$(wxOutDirName);%(AdditionalLibraryDirectories)</AdditionalLibraryDirectories>
|
||||
<GenerateDebugInformation>true</GenerateDebugInformation>
|
||||
<SubSystem>Windows</SubSystem>
|
||||
<TargetMachine>MachineX64</TargetMachine>
|
||||
<OptimizeReferences>true</OptimizeReferences>
|
||||
<EnableCOMDATFolding>true</EnableCOMDATFolding>
|
||||
</Link>
|
||||
<Bscmake>
|
||||
<SuppressStartupBanner>true</SuppressStartupBanner>
|
||||
</Bscmake>
|
||||
<Manifest>
|
||||
<AdditionalManifestFiles>./../../include/wx/msw/wx_dpi_aware_pmv2.manifest %(AdditionalManifestFiles)</AdditionalManifestFiles>
|
||||
</Manifest>
|
||||
</ItemDefinitionGroup>
|
||||
<ItemGroup>
|
||||
<ClCompile Include="doc.cpp" />
|
||||
<ClCompile Include="docview.cpp" />
|
||||
<ClCompile Include="view.cpp" />
|
||||
</ItemGroup>
|
||||
<ItemGroup>
|
||||
<ResourceCompile Include="docview.rc" />
|
||||
</ItemGroup>
|
||||
<Import Project="$(VCTargetsPath)\Microsoft.Cpp.targets" />
|
||||
<ImportGroup Label="ExtensionTargets">
|
||||
</ImportGroup>
|
||||
</Project>
|
||||
29
libs/wxWidgets-3.3.1/samples/docview/docview.vcxproj.filters
Normal file
29
libs/wxWidgets-3.3.1/samples/docview/docview.vcxproj.filters
Normal file
@@ -0,0 +1,29 @@
|
||||
<?xml version="1.0" encoding="utf-8"?>
|
||||
<Project ToolsVersion="4.0" xmlns="http://schemas.microsoft.com/developer/msbuild/2003">
|
||||
<ItemGroup>
|
||||
<Filter Include="Source Files">
|
||||
<UniqueIdentifier>{4FC737F1-C7A5-4376-A066-2A32D752A2FF}</UniqueIdentifier>
|
||||
<Extensions>cpp;c;cc;cxx;def;odl;idl;hpj;bat;asm;asmx</Extensions>
|
||||
</Filter>
|
||||
<Filter Include="Resource Files">
|
||||
<UniqueIdentifier>{67DA6AB6-F800-4c08-8B7A-83BB121AAD01}</UniqueIdentifier>
|
||||
<Extensions>rc;ico;cur;bmp;dlg;rc2;rct;bin;rgs;gif;jpg;jpeg;jpe;resx;tiff;tif;png;wav</Extensions>
|
||||
</Filter>
|
||||
</ItemGroup>
|
||||
<ItemGroup>
|
||||
<ClCompile Include="docview.cpp">
|
||||
<Filter>Source Files</Filter>
|
||||
</ClCompile>
|
||||
<ClCompile Include="doc.cpp">
|
||||
<Filter>Source Files</Filter>
|
||||
</ClCompile>
|
||||
<ClCompile Include="view.cpp">
|
||||
<Filter>Source Files</Filter>
|
||||
</ClCompile>
|
||||
</ItemGroup>
|
||||
<ItemGroup>
|
||||
<ResourceCompile Include="docview.rc">
|
||||
<Filter>Resource Files</Filter>
|
||||
</ResourceCompile>
|
||||
</ItemGroup>
|
||||
</Project>
|
||||
240
libs/wxWidgets-3.3.1/samples/docview/makefile.gcc
Normal file
240
libs/wxWidgets-3.3.1/samples/docview/makefile.gcc
Normal file
@@ -0,0 +1,240 @@
|
||||
# =========================================================================
|
||||
# This makefile was generated by
|
||||
# Bakefile 0.2.13 (http://www.bakefile.org)
|
||||
# Do not modify, all changes will be overwritten!
|
||||
# =========================================================================
|
||||
|
||||
include ../../build/msw/config.gcc
|
||||
|
||||
# -------------------------------------------------------------------------
|
||||
# Do not modify the rest of this file!
|
||||
# -------------------------------------------------------------------------
|
||||
|
||||
### Variables: ###
|
||||
|
||||
CPPDEPS = -MT$@ -MF$@.d -MD -MP
|
||||
WX_RELEASE_NODOT = 33
|
||||
COMPILER_PREFIX = gcc
|
||||
OBJS = \
|
||||
$(COMPILER_PREFIX)$(COMPILER_VERSION)_$(PORTNAME)$(WXUNIVNAME)u$(WXDEBUGFLAG)$(WXDLLFLAG)$(CFG)
|
||||
LIBDIRNAME = \
|
||||
.\..\..\lib\$(COMPILER_PREFIX)$(COMPILER_VERSION)_$(LIBTYPE_SUFFIX)$(CFG)
|
||||
SETUPHDIR = $(LIBDIRNAME)\$(PORTNAME)$(WXUNIVNAME)u$(WXDEBUGFLAG)
|
||||
DOCVIEW_CXXFLAGS = $(__DEBUGINFO) $(__OPTIMIZEFLAG_2) $(__THREADSFLAG) \
|
||||
-D__WXMSW__ $(__WXUNIV_DEFINE_p) $(__DEBUG_DEFINE_p) $(__NDEBUG_DEFINE_p) \
|
||||
$(__EXCEPTIONS_DEFINE_p) $(__RTTI_DEFINE_p) $(__THREAD_DEFINE_p) \
|
||||
-I$(SETUPHDIR) -I.\..\..\include $(____CAIRO_INCLUDEDIR_FILENAMES_p) -W \
|
||||
-Wall -I. $(__DLLFLAG_p) -I.\..\..\samples -DNOPCH $(__RTTIFLAG_5) \
|
||||
$(__EXCEPTIONSFLAG_6) -Wno-ctor-dtor-privacy $(CPPFLAGS) $(CXXFLAGS)
|
||||
DOCVIEW_OBJECTS = \
|
||||
$(OBJS)\docview_docview.o \
|
||||
$(OBJS)\docview_doc.o \
|
||||
$(OBJS)\docview_view.o \
|
||||
$(OBJS)\docview_docview_rc.o
|
||||
|
||||
### Conditionally set variables: ###
|
||||
|
||||
ifeq ($(USE_GUI),0)
|
||||
PORTNAME = base
|
||||
endif
|
||||
ifeq ($(USE_GUI),1)
|
||||
PORTNAME = msw$(TOOLKIT_VERSION)
|
||||
endif
|
||||
ifeq ($(OFFICIAL_BUILD),1)
|
||||
COMPILER_VERSION = ERROR-COMPILER-VERSION-MUST-BE-SET-FOR-OFFICIAL-BUILD
|
||||
endif
|
||||
ifeq ($(BUILD),debug)
|
||||
WXDEBUGFLAG = d
|
||||
endif
|
||||
ifeq ($(WXUNIV),1)
|
||||
WXUNIVNAME = univ
|
||||
endif
|
||||
ifeq ($(SHARED),1)
|
||||
WXDLLFLAG = dll
|
||||
endif
|
||||
ifeq ($(SHARED),0)
|
||||
LIBTYPE_SUFFIX = lib
|
||||
endif
|
||||
ifeq ($(SHARED),1)
|
||||
LIBTYPE_SUFFIX = dll
|
||||
endif
|
||||
ifeq ($(MONOLITHIC),0)
|
||||
EXTRALIBS_FOR_BASE =
|
||||
endif
|
||||
ifeq ($(MONOLITHIC),1)
|
||||
EXTRALIBS_FOR_BASE =
|
||||
endif
|
||||
ifeq ($(BUILD),debug)
|
||||
__OPTIMIZEFLAG_2 = -O0
|
||||
endif
|
||||
ifeq ($(BUILD),release)
|
||||
__OPTIMIZEFLAG_2 = -O2
|
||||
endif
|
||||
ifeq ($(USE_RTTI),0)
|
||||
__RTTIFLAG_5 = -fno-rtti
|
||||
endif
|
||||
ifeq ($(USE_RTTI),1)
|
||||
__RTTIFLAG_5 =
|
||||
endif
|
||||
ifeq ($(USE_EXCEPTIONS),0)
|
||||
__EXCEPTIONSFLAG_6 = -fno-exceptions
|
||||
endif
|
||||
ifeq ($(USE_EXCEPTIONS),1)
|
||||
__EXCEPTIONSFLAG_6 =
|
||||
endif
|
||||
ifeq ($(WXUNIV),1)
|
||||
__WXUNIV_DEFINE_p = -D__WXUNIVERSAL__
|
||||
endif
|
||||
ifeq ($(WXUNIV),1)
|
||||
__WXUNIV_DEFINE_p_1 = --define __WXUNIVERSAL__
|
||||
endif
|
||||
ifeq ($(DEBUG_FLAG),0)
|
||||
__DEBUG_DEFINE_p = -DwxDEBUG_LEVEL=0
|
||||
endif
|
||||
ifeq ($(DEBUG_FLAG),0)
|
||||
__DEBUG_DEFINE_p_1 = --define wxDEBUG_LEVEL=0
|
||||
endif
|
||||
ifeq ($(BUILD),release)
|
||||
__NDEBUG_DEFINE_p = -DNDEBUG
|
||||
endif
|
||||
ifeq ($(BUILD),release)
|
||||
__NDEBUG_DEFINE_p_1 = --define NDEBUG
|
||||
endif
|
||||
ifeq ($(USE_EXCEPTIONS),0)
|
||||
__EXCEPTIONS_DEFINE_p = -DwxNO_EXCEPTIONS
|
||||
endif
|
||||
ifeq ($(USE_EXCEPTIONS),0)
|
||||
__EXCEPTIONS_DEFINE_p_1 = --define wxNO_EXCEPTIONS
|
||||
endif
|
||||
ifeq ($(USE_RTTI),0)
|
||||
__RTTI_DEFINE_p = -DwxNO_RTTI
|
||||
endif
|
||||
ifeq ($(USE_RTTI),0)
|
||||
__RTTI_DEFINE_p_1 = --define wxNO_RTTI
|
||||
endif
|
||||
ifeq ($(USE_THREADS),0)
|
||||
__THREAD_DEFINE_p = -DwxNO_THREADS
|
||||
endif
|
||||
ifeq ($(USE_THREADS),0)
|
||||
__THREAD_DEFINE_p_1 = --define wxNO_THREADS
|
||||
endif
|
||||
ifeq ($(USE_CAIRO),1)
|
||||
____CAIRO_INCLUDEDIR_FILENAMES_p = -I$(CAIRO_ROOT)\include\cairo
|
||||
endif
|
||||
ifeq ($(USE_CAIRO),1)
|
||||
__CAIRO_INCLUDEDIR_p = --include-dir $(CAIRO_ROOT)/include/cairo
|
||||
endif
|
||||
ifeq ($(SHARED),1)
|
||||
__DLLFLAG_p = -DWXUSINGDLL
|
||||
endif
|
||||
ifeq ($(SHARED),1)
|
||||
__DLLFLAG_p_1 = --define WXUSINGDLL
|
||||
endif
|
||||
ifeq ($(MONOLITHIC),0)
|
||||
__WXLIB_AUI_p = \
|
||||
-lwx$(PORTNAME)$(WXUNIVNAME)$(WX_RELEASE_NODOT)u$(WXDEBUGFLAG)$(WX_LIB_FLAVOUR)_aui
|
||||
endif
|
||||
ifeq ($(MONOLITHIC),0)
|
||||
__WXLIB_CORE_p = \
|
||||
-lwx$(PORTNAME)$(WXUNIVNAME)$(WX_RELEASE_NODOT)u$(WXDEBUGFLAG)$(WX_LIB_FLAVOUR)_core
|
||||
endif
|
||||
ifeq ($(MONOLITHIC),0)
|
||||
__WXLIB_BASE_p = -lwxbase$(WX_RELEASE_NODOT)u$(WXDEBUGFLAG)$(WX_LIB_FLAVOUR)
|
||||
endif
|
||||
ifeq ($(MONOLITHIC),1)
|
||||
__WXLIB_MONO_p = \
|
||||
-lwx$(PORTNAME)$(WXUNIVNAME)$(WX_RELEASE_NODOT)u$(WXDEBUGFLAG)$(WX_LIB_FLAVOUR)
|
||||
endif
|
||||
ifeq ($(MONOLITHIC),1)
|
||||
ifeq ($(USE_STC),1)
|
||||
__LIB_SCINTILLA_IF_MONO_p = -lwxscintilla$(WXDEBUGFLAG)
|
||||
endif
|
||||
endif
|
||||
ifeq ($(MONOLITHIC),1)
|
||||
ifeq ($(USE_STC),1)
|
||||
__LIB_LEXILLA_IF_MONO_p = $(__LIB_LEXILLA_p)
|
||||
endif
|
||||
endif
|
||||
ifeq ($(USE_STC),1)
|
||||
__LIB_LEXILLA_p = -lwxlexilla$(WXDEBUGFLAG)
|
||||
endif
|
||||
ifeq ($(USE_GUI),1)
|
||||
__LIB_TIFF_p = -lwxtiff$(WXDEBUGFLAG)
|
||||
endif
|
||||
ifeq ($(USE_GUI),1)
|
||||
__LIB_JPEG_p = -lwxjpeg$(WXDEBUGFLAG)
|
||||
endif
|
||||
ifeq ($(USE_GUI),1)
|
||||
__LIB_PNG_p = -lwxpng$(WXDEBUGFLAG)
|
||||
endif
|
||||
ifeq ($(USE_GUI),1)
|
||||
__LIB_WEBP_p = -lwxwebp$(WXDEBUGFLAG)
|
||||
endif
|
||||
ifeq ($(USE_CAIRO),1)
|
||||
__CAIRO_LIB_p = -lcairo
|
||||
endif
|
||||
ifeq ($(USE_CAIRO),1)
|
||||
____CAIRO_LIBDIR_FILENAMES_p = -L$(CAIRO_ROOT)\lib
|
||||
endif
|
||||
ifeq ($(BUILD),debug)
|
||||
ifeq ($(DEBUG_INFO),default)
|
||||
__DEBUGINFO = -g
|
||||
endif
|
||||
endif
|
||||
ifeq ($(BUILD),release)
|
||||
ifeq ($(DEBUG_INFO),default)
|
||||
__DEBUGINFO =
|
||||
endif
|
||||
endif
|
||||
ifeq ($(DEBUG_INFO),0)
|
||||
__DEBUGINFO =
|
||||
endif
|
||||
ifeq ($(DEBUG_INFO),1)
|
||||
__DEBUGINFO = -g
|
||||
endif
|
||||
ifeq ($(USE_THREADS),0)
|
||||
__THREADSFLAG =
|
||||
endif
|
||||
ifeq ($(USE_THREADS),1)
|
||||
__THREADSFLAG = -mthreads
|
||||
endif
|
||||
|
||||
|
||||
all: $(OBJS)
|
||||
$(OBJS):
|
||||
-if not exist $(OBJS) mkdir $(OBJS)
|
||||
|
||||
### Targets: ###
|
||||
|
||||
all: $(OBJS)\docview.exe
|
||||
|
||||
clean:
|
||||
-if exist $(OBJS)\*.o del $(OBJS)\*.o
|
||||
-if exist $(OBJS)\*.d del $(OBJS)\*.d
|
||||
-if exist $(OBJS)\docview.exe del $(OBJS)\docview.exe
|
||||
|
||||
$(OBJS)\docview.exe: $(DOCVIEW_OBJECTS) $(OBJS)\docview_docview_rc.o
|
||||
$(foreach f,$(subst \,/,$(DOCVIEW_OBJECTS)),$(shell echo $f >> $(subst \,/,$@).rsp.tmp))
|
||||
@move /y $@.rsp.tmp $@.rsp >nul
|
||||
$(CXX) -o $@ @$@.rsp $(__DEBUGINFO) $(__THREADSFLAG) -L$(LIBDIRNAME) -Wl,--subsystem,windows -mwindows $(____CAIRO_LIBDIR_FILENAMES_p) $(LDFLAGS) $(__WXLIB_AUI_p) $(__WXLIB_CORE_p) $(__WXLIB_BASE_p) $(__WXLIB_MONO_p) $(__LIB_SCINTILLA_IF_MONO_p) $(__LIB_LEXILLA_IF_MONO_p) $(__LIB_TIFF_p) $(__LIB_JPEG_p) $(__LIB_PNG_p) $(__LIB_WEBP_p) -lwxzlib$(WXDEBUGFLAG) -lwxregexu$(WXDEBUGFLAG) -lwxexpat$(WXDEBUGFLAG) $(EXTRALIBS_FOR_BASE) $(__CAIRO_LIB_p) -lkernel32 -luser32 -lgdi32 -lgdiplus -lmsimg32 -lcomdlg32 -lwinspool -lwinmm -lshell32 -lshlwapi -lcomctl32 -lole32 -loleaut32 -luuid -lrpcrt4 -ladvapi32 -lversion -lws2_32 -lwininet -loleacc -luxtheme
|
||||
@-del $@.rsp
|
||||
|
||||
$(OBJS)\docview_docview.o: ./docview.cpp
|
||||
$(CXX) -c -o $@ $(DOCVIEW_CXXFLAGS) $(CPPDEPS) $<
|
||||
|
||||
$(OBJS)\docview_doc.o: ./doc.cpp
|
||||
$(CXX) -c -o $@ $(DOCVIEW_CXXFLAGS) $(CPPDEPS) $<
|
||||
|
||||
$(OBJS)\docview_view.o: ./view.cpp
|
||||
$(CXX) -c -o $@ $(DOCVIEW_CXXFLAGS) $(CPPDEPS) $<
|
||||
|
||||
$(OBJS)\docview_docview_rc.o: ./docview.rc
|
||||
$(WINDRES) -i$< -o$@ --define __WXMSW__ $(__WXUNIV_DEFINE_p_1) $(__DEBUG_DEFINE_p_1) $(__NDEBUG_DEFINE_p_1) $(__EXCEPTIONS_DEFINE_p_1) $(__RTTI_DEFINE_p_1) $(__THREAD_DEFINE_p_1) --include-dir $(SETUPHDIR) --include-dir ./../../include $(__CAIRO_INCLUDEDIR_p) --include-dir . $(__DLLFLAG_p_1) --define wxUSE_DPI_AWARE_MANIFEST=$(USE_DPI_AWARE_MANIFEST) --include-dir ./../../samples --define NOPCH
|
||||
|
||||
.PHONY: all clean
|
||||
|
||||
|
||||
SHELL := $(COMSPEC)
|
||||
|
||||
# Dependencies tracking:
|
||||
-include $(OBJS)/*.d
|
||||
108
libs/wxWidgets-3.3.1/samples/docview/makefile.unx
Normal file
108
libs/wxWidgets-3.3.1/samples/docview/makefile.unx
Normal file
@@ -0,0 +1,108 @@
|
||||
# =========================================================================
|
||||
# This makefile was generated by
|
||||
# Bakefile 0.2.13 (http://www.bakefile.org)
|
||||
# Do not modify, all changes will be overwritten!
|
||||
# =========================================================================
|
||||
|
||||
|
||||
|
||||
# -------------------------------------------------------------------------
|
||||
# These are configurable options:
|
||||
# -------------------------------------------------------------------------
|
||||
|
||||
# C++ compiler
|
||||
CXX = `$(WX_CONFIG) --cxx`
|
||||
|
||||
# Standard flags for C++
|
||||
CXXFLAGS ?=
|
||||
|
||||
# Standard preprocessor flags (common for CC and CXX)
|
||||
CPPFLAGS ?=
|
||||
|
||||
# Standard linker flags
|
||||
LDFLAGS ?=
|
||||
|
||||
# Location and arguments of wx-config script
|
||||
WX_CONFIG ?= wx-config
|
||||
|
||||
# Port of the wx library to build against [gtk2,msw,x11,osx_cocoa,osx_carbon,dfb]
|
||||
WX_PORT ?= $(shell $(WX_CONFIG) --query-toolkit)
|
||||
|
||||
# Use DLL build of wx library to use? [0,1]
|
||||
WX_SHARED ?= $(shell if test -z `$(WX_CONFIG) --query-linkage`; then echo 1; else echo 0; fi)
|
||||
|
||||
# Compile Unicode build of wxWidgets? [0,1]
|
||||
WX_UNICODE ?= $(shell $(WX_CONFIG) --query-chartype | sed 's/unicode/1/;s/ansi/0/')
|
||||
|
||||
# Version of the wx library to build against.
|
||||
WX_VERSION ?= $(shell $(WX_CONFIG) --query-version | sed -e 's/\([0-9]*\)\.\([0-9]*\)/\1\2/')
|
||||
|
||||
|
||||
|
||||
# -------------------------------------------------------------------------
|
||||
# Do not modify the rest of this file!
|
||||
# -------------------------------------------------------------------------
|
||||
|
||||
### Variables: ###
|
||||
|
||||
CPPDEPS = -MT$@ -MF`echo $@ | sed -e 's,\.o$$,.d,'` -MD -MP
|
||||
WX_VERSION_MAJOR = $(shell echo $(WX_VERSION) | cut -c1,1)
|
||||
WX_VERSION_MINOR = $(shell echo $(WX_VERSION) | cut -c2,2)
|
||||
WX_CONFIG_FLAGS = $(WX_CONFIG_UNICODE_FLAG) $(WX_CONFIG_SHARED_FLAG) \
|
||||
--toolkit=$(WX_PORT) --version=$(WX_VERSION_MAJOR).$(WX_VERSION_MINOR)
|
||||
DOCVIEW_CXXFLAGS = -I. `$(WX_CONFIG) --cxxflags $(WX_CONFIG_FLAGS)` $(CPPFLAGS) \
|
||||
$(CXXFLAGS)
|
||||
DOCVIEW_OBJECTS = \
|
||||
docview_docview.o \
|
||||
docview_doc.o \
|
||||
docview_view.o
|
||||
|
||||
### Conditionally set variables: ###
|
||||
|
||||
ifeq ($(WX_UNICODE),0)
|
||||
WX_CONFIG_UNICODE_FLAG = --unicode=no
|
||||
endif
|
||||
ifeq ($(WX_UNICODE),1)
|
||||
WX_CONFIG_UNICODE_FLAG = --unicode=yes
|
||||
endif
|
||||
ifeq ($(WX_SHARED),0)
|
||||
WX_CONFIG_SHARED_FLAG = --static=yes
|
||||
endif
|
||||
ifeq ($(WX_SHARED),1)
|
||||
WX_CONFIG_SHARED_FLAG = --static=no
|
||||
endif
|
||||
|
||||
|
||||
### Targets: ###
|
||||
|
||||
all: test_for_selected_wxbuild docview
|
||||
|
||||
install:
|
||||
|
||||
uninstall:
|
||||
|
||||
clean:
|
||||
rm -f ./*.o
|
||||
rm -f ./*.d
|
||||
rm -f docview
|
||||
|
||||
test_for_selected_wxbuild:
|
||||
@$(WX_CONFIG) $(WX_CONFIG_FLAGS)
|
||||
|
||||
docview: $(DOCVIEW_OBJECTS)
|
||||
$(CXX) -o $@ $(DOCVIEW_OBJECTS) $(LDFLAGS) `$(WX_CONFIG) $(WX_CONFIG_FLAGS) --libs aui,core,base`
|
||||
|
||||
docview_docview.o: ./docview.cpp
|
||||
$(CXX) -c -o $@ $(DOCVIEW_CXXFLAGS) $(CPPDEPS) $<
|
||||
|
||||
docview_doc.o: ./doc.cpp
|
||||
$(CXX) -c -o $@ $(DOCVIEW_CXXFLAGS) $(CPPDEPS) $<
|
||||
|
||||
docview_view.o: ./view.cpp
|
||||
$(CXX) -c -o $@ $(DOCVIEW_CXXFLAGS) $(CPPDEPS) $<
|
||||
|
||||
.PHONY: all install uninstall clean
|
||||
|
||||
|
||||
# Dependencies tracking:
|
||||
-include ./*.d
|
||||
453
libs/wxWidgets-3.3.1/samples/docview/makefile.vc
Normal file
453
libs/wxWidgets-3.3.1/samples/docview/makefile.vc
Normal file
@@ -0,0 +1,453 @@
|
||||
# =========================================================================
|
||||
# This makefile was generated by
|
||||
# Bakefile 0.2.13 (http://www.bakefile.org)
|
||||
# Do not modify, all changes will be overwritten!
|
||||
# =========================================================================
|
||||
|
||||
!include <../../build/msw/config.vc>
|
||||
|
||||
# -------------------------------------------------------------------------
|
||||
# Do not modify the rest of this file!
|
||||
# -------------------------------------------------------------------------
|
||||
|
||||
### Variables: ###
|
||||
|
||||
WX_RELEASE_NODOT = 33
|
||||
COMPILER_PREFIX = vc
|
||||
OBJS = \
|
||||
$(COMPILER_PREFIX)$(COMPILER_VERSION)$(ARCH_SUFFIX)_$(PORTNAME)$(WXUNIVNAME)u$(WXDEBUGFLAG)$(WXDLLFLAG)$(CFG)
|
||||
LIBDIRNAME = \
|
||||
.\..\..\lib\$(COMPILER_PREFIX)$(COMPILER_VERSION)$(ARCH_SUFFIX)_$(LIBTYPE_SUFFIX)$(CFG)
|
||||
SETUPHDIR = $(LIBDIRNAME)\$(PORTNAME)$(WXUNIVNAME)u$(WXDEBUGFLAG)
|
||||
DOCVIEW_CXXFLAGS = /M$(__RUNTIME_LIBS_10)$(__DEBUGRUNTIME_4) /DWIN32 \
|
||||
$(__DEBUGINFO_0) /Fd$(OBJS)\docview.pdb $(____DEBUGRUNTIME_3_p) \
|
||||
$(__OPTIMIZEFLAG_6) /D_CRT_SECURE_NO_DEPRECATE=1 \
|
||||
/D_CRT_NON_CONFORMING_SWPRINTFS=1 /D_SCL_SECURE_NO_WARNINGS=1 \
|
||||
$(__NO_VC_CRTDBG_p) $(__TARGET_CPU_COMPFLAG_p) /D__WXMSW__ \
|
||||
$(__WXUNIV_DEFINE_p) $(__DEBUG_DEFINE_p) $(__NDEBUG_DEFINE_p) \
|
||||
$(__EXCEPTIONS_DEFINE_p) $(__RTTI_DEFINE_p) $(__THREAD_DEFINE_p) \
|
||||
/I$(SETUPHDIR) /I.\..\..\include $(____CAIRO_INCLUDEDIR_FILENAMES_p) /W4 /I. \
|
||||
$(__DLLFLAG_p) /D_WINDOWS /I.\..\..\samples /DNOPCH $(__RTTIFLAG_11) \
|
||||
$(__EXCEPTIONSFLAG_12) $(CPPFLAGS) $(CXXFLAGS)
|
||||
DOCVIEW_OBJECTS = \
|
||||
$(OBJS)\docview_docview.obj \
|
||||
$(OBJS)\docview_doc.obj \
|
||||
$(OBJS)\docview_view.obj
|
||||
DOCVIEW_RESOURCES = \
|
||||
$(OBJS)\docview_docview.res
|
||||
|
||||
### Conditionally set variables: ###
|
||||
|
||||
!if "$(TARGET_CPU)" == "AMD64"
|
||||
ARCH_SUFFIX = _x64
|
||||
!endif
|
||||
!if "$(TARGET_CPU)" == "ARM"
|
||||
ARCH_SUFFIX = _arm
|
||||
!endif
|
||||
!if "$(TARGET_CPU)" == "ARM64"
|
||||
ARCH_SUFFIX = _arm64
|
||||
!endif
|
||||
!if "$(TARGET_CPU)" == "IA64"
|
||||
ARCH_SUFFIX = _ia64
|
||||
!endif
|
||||
!if "$(TARGET_CPU)" == "X64"
|
||||
ARCH_SUFFIX = _x64
|
||||
!endif
|
||||
!if "$(TARGET_CPU)" == "" && "$(VISUALSTUDIOPLATFORM)" == "X64"
|
||||
ARCH_SUFFIX = _x64
|
||||
!endif
|
||||
!if "$(TARGET_CPU)" == "" && "$(VISUALSTUDIOPLATFORM)" == "x64"
|
||||
ARCH_SUFFIX = _x64
|
||||
!endif
|
||||
!if "$(TARGET_CPU)" == "amd64"
|
||||
ARCH_SUFFIX = _x64
|
||||
!endif
|
||||
!if "$(TARGET_CPU)" == "arm"
|
||||
ARCH_SUFFIX = _arm
|
||||
!endif
|
||||
!if "$(TARGET_CPU)" == "arm64"
|
||||
ARCH_SUFFIX = _arm64
|
||||
!endif
|
||||
!if "$(TARGET_CPU)" == "ia64"
|
||||
ARCH_SUFFIX = _ia64
|
||||
!endif
|
||||
!if "$(TARGET_CPU)" == "x64"
|
||||
ARCH_SUFFIX = _x64
|
||||
!endif
|
||||
!if "$(USE_GUI)" == "0"
|
||||
PORTNAME = base
|
||||
!endif
|
||||
!if "$(USE_GUI)" == "1"
|
||||
PORTNAME = msw$(TOOLKIT_VERSION)
|
||||
!endif
|
||||
!if "$(OFFICIAL_BUILD)" == "1"
|
||||
COMPILER_VERSION = ERROR-COMPILER-VERSION-MUST-BE-SET-FOR-OFFICIAL-BUILD
|
||||
!endif
|
||||
!if "$(BUILD)" == "debug" && "$(DEBUG_RUNTIME_LIBS)" == "default"
|
||||
WXDEBUGFLAG = d
|
||||
!endif
|
||||
!if "$(DEBUG_RUNTIME_LIBS)" == "1"
|
||||
WXDEBUGFLAG = d
|
||||
!endif
|
||||
!if "$(WXUNIV)" == "1"
|
||||
WXUNIVNAME = univ
|
||||
!endif
|
||||
!if "$(SHARED)" == "1"
|
||||
WXDLLFLAG = dll
|
||||
!endif
|
||||
!if "$(SHARED)" == "0"
|
||||
LIBTYPE_SUFFIX = lib
|
||||
!endif
|
||||
!if "$(SHARED)" == "1"
|
||||
LIBTYPE_SUFFIX = dll
|
||||
!endif
|
||||
!if "$(TARGET_CPU)" == "AMD64"
|
||||
LINK_TARGET_CPU = /MACHINE:X64
|
||||
!endif
|
||||
!if "$(TARGET_CPU)" == "ARM"
|
||||
LINK_TARGET_CPU = /MACHINE:ARM
|
||||
!endif
|
||||
!if "$(TARGET_CPU)" == "ARM64"
|
||||
LINK_TARGET_CPU = /MACHINE:ARM64
|
||||
!endif
|
||||
!if "$(TARGET_CPU)" == "IA64"
|
||||
LINK_TARGET_CPU = /MACHINE:IA64
|
||||
!endif
|
||||
!if "$(TARGET_CPU)" == "X64"
|
||||
LINK_TARGET_CPU = /MACHINE:X64
|
||||
!endif
|
||||
!if "$(TARGET_CPU)" == "" && "$(VISUALSTUDIOPLATFORM)" == "X64"
|
||||
LINK_TARGET_CPU = /MACHINE:X64
|
||||
!endif
|
||||
!if "$(TARGET_CPU)" == "" && "$(VISUALSTUDIOPLATFORM)" == "x64"
|
||||
LINK_TARGET_CPU = /MACHINE:X64
|
||||
!endif
|
||||
!if "$(TARGET_CPU)" == "amd64"
|
||||
LINK_TARGET_CPU = /MACHINE:X64
|
||||
!endif
|
||||
!if "$(TARGET_CPU)" == "arm"
|
||||
LINK_TARGET_CPU = /MACHINE:ARM
|
||||
!endif
|
||||
!if "$(TARGET_CPU)" == "arm64"
|
||||
LINK_TARGET_CPU = /MACHINE:ARM64
|
||||
!endif
|
||||
!if "$(TARGET_CPU)" == "ia64"
|
||||
LINK_TARGET_CPU = /MACHINE:IA64
|
||||
!endif
|
||||
!if "$(TARGET_CPU)" == "x64"
|
||||
LINK_TARGET_CPU = /MACHINE:X64
|
||||
!endif
|
||||
!if "$(USE_DPI_AWARE_MANIFEST)" == "1" && "$(VISUALSTUDIOVERSION)" == "14.0"
|
||||
WIN32_DPI_LINKFLAG = /MANIFEST:EMBED \
|
||||
/MANIFESTINPUT:./../../include/wx/msw/wx_dpi_aware.manifest
|
||||
!endif
|
||||
!if "$(USE_DPI_AWARE_MANIFEST)" == "1" && "$(VISUALSTUDIOVERSION)" == "15.0"
|
||||
WIN32_DPI_LINKFLAG = /MANIFEST:EMBED \
|
||||
/MANIFESTINPUT:./../../include/wx/msw/wx_dpi_aware.manifest
|
||||
!endif
|
||||
!if "$(USE_DPI_AWARE_MANIFEST)" == "1" && "$(VISUALSTUDIOVERSION)" == "16.0"
|
||||
WIN32_DPI_LINKFLAG = /MANIFEST:EMBED \
|
||||
/MANIFESTINPUT:./../../include/wx/msw/wx_dpi_aware.manifest
|
||||
!endif
|
||||
!if "$(USE_DPI_AWARE_MANIFEST)" == "1" && "$(VISUALSTUDIOVERSION)" == "17.0"
|
||||
WIN32_DPI_LINKFLAG = /MANIFEST:EMBED \
|
||||
/MANIFESTINPUT:./../../include/wx/msw/wx_dpi_aware.manifest
|
||||
!endif
|
||||
!if "$(USE_DPI_AWARE_MANIFEST)" == "2" && "$(VISUALSTUDIOVERSION)" == "14.0"
|
||||
WIN32_DPI_LINKFLAG = /MANIFEST:EMBED \
|
||||
/MANIFESTINPUT:./../../include/wx/msw/wx_dpi_aware_pmv2.manifest
|
||||
!endif
|
||||
!if "$(USE_DPI_AWARE_MANIFEST)" == "2" && "$(VISUALSTUDIOVERSION)" == "15.0"
|
||||
WIN32_DPI_LINKFLAG = /MANIFEST:EMBED \
|
||||
/MANIFESTINPUT:./../../include/wx/msw/wx_dpi_aware_pmv2.manifest
|
||||
!endif
|
||||
!if "$(USE_DPI_AWARE_MANIFEST)" == "2" && "$(VISUALSTUDIOVERSION)" == "16.0"
|
||||
WIN32_DPI_LINKFLAG = /MANIFEST:EMBED \
|
||||
/MANIFESTINPUT:./../../include/wx/msw/wx_dpi_aware_pmv2.manifest
|
||||
!endif
|
||||
!if "$(USE_DPI_AWARE_MANIFEST)" == "2" && "$(VISUALSTUDIOVERSION)" == "17.0"
|
||||
WIN32_DPI_LINKFLAG = /MANIFEST:EMBED \
|
||||
/MANIFESTINPUT:./../../include/wx/msw/wx_dpi_aware_pmv2.manifest
|
||||
!endif
|
||||
!if "$(MONOLITHIC)" == "0"
|
||||
EXTRALIBS_FOR_BASE =
|
||||
!endif
|
||||
!if "$(MONOLITHIC)" == "1"
|
||||
EXTRALIBS_FOR_BASE =
|
||||
!endif
|
||||
!if "$(BUILD)" == "debug" && "$(DEBUG_INFO)" == "default"
|
||||
__DEBUGINFO_0 = /Zi
|
||||
!endif
|
||||
!if "$(BUILD)" == "release" && "$(DEBUG_INFO)" == "default"
|
||||
__DEBUGINFO_0 =
|
||||
!endif
|
||||
!if "$(DEBUG_INFO)" == "0"
|
||||
__DEBUGINFO_0 =
|
||||
!endif
|
||||
!if "$(DEBUG_INFO)" == "1"
|
||||
__DEBUGINFO_0 = /Zi
|
||||
!endif
|
||||
!if "$(BUILD)" == "debug" && "$(DEBUG_INFO)" == "default"
|
||||
__DEBUGINFO_1 = /DEBUG
|
||||
!endif
|
||||
!if "$(BUILD)" == "release" && "$(DEBUG_INFO)" == "default"
|
||||
__DEBUGINFO_1 =
|
||||
!endif
|
||||
!if "$(DEBUG_INFO)" == "0"
|
||||
__DEBUGINFO_1 =
|
||||
!endif
|
||||
!if "$(DEBUG_INFO)" == "1"
|
||||
__DEBUGINFO_1 = /DEBUG
|
||||
!endif
|
||||
!if "$(BUILD)" == "debug" && "$(DEBUG_INFO)" == "default"
|
||||
__DEBUGINFO_2 = $(__DEBUGRUNTIME_5)
|
||||
!endif
|
||||
!if "$(BUILD)" == "release" && "$(DEBUG_INFO)" == "default"
|
||||
__DEBUGINFO_2 =
|
||||
!endif
|
||||
!if "$(DEBUG_INFO)" == "0"
|
||||
__DEBUGINFO_2 =
|
||||
!endif
|
||||
!if "$(DEBUG_INFO)" == "1"
|
||||
__DEBUGINFO_2 = $(__DEBUGRUNTIME_5)
|
||||
!endif
|
||||
!if "$(BUILD)" == "debug" && "$(DEBUG_RUNTIME_LIBS)" == "default"
|
||||
____DEBUGRUNTIME_3_p = /D_DEBUG
|
||||
!endif
|
||||
!if "$(BUILD)" == "release" && "$(DEBUG_RUNTIME_LIBS)" == "default"
|
||||
____DEBUGRUNTIME_3_p =
|
||||
!endif
|
||||
!if "$(DEBUG_RUNTIME_LIBS)" == "0"
|
||||
____DEBUGRUNTIME_3_p =
|
||||
!endif
|
||||
!if "$(DEBUG_RUNTIME_LIBS)" == "1"
|
||||
____DEBUGRUNTIME_3_p = /D_DEBUG
|
||||
!endif
|
||||
!if "$(BUILD)" == "debug" && "$(DEBUG_RUNTIME_LIBS)" == "default"
|
||||
____DEBUGRUNTIME_3_p_1 = /d _DEBUG
|
||||
!endif
|
||||
!if "$(BUILD)" == "release" && "$(DEBUG_RUNTIME_LIBS)" == "default"
|
||||
____DEBUGRUNTIME_3_p_1 =
|
||||
!endif
|
||||
!if "$(DEBUG_RUNTIME_LIBS)" == "0"
|
||||
____DEBUGRUNTIME_3_p_1 =
|
||||
!endif
|
||||
!if "$(DEBUG_RUNTIME_LIBS)" == "1"
|
||||
____DEBUGRUNTIME_3_p_1 = /d _DEBUG
|
||||
!endif
|
||||
!if "$(BUILD)" == "debug" && "$(DEBUG_RUNTIME_LIBS)" == "default"
|
||||
__DEBUGRUNTIME_4 = d
|
||||
!endif
|
||||
!if "$(BUILD)" == "release" && "$(DEBUG_RUNTIME_LIBS)" == "default"
|
||||
__DEBUGRUNTIME_4 =
|
||||
!endif
|
||||
!if "$(DEBUG_RUNTIME_LIBS)" == "0"
|
||||
__DEBUGRUNTIME_4 =
|
||||
!endif
|
||||
!if "$(DEBUG_RUNTIME_LIBS)" == "1"
|
||||
__DEBUGRUNTIME_4 = d
|
||||
!endif
|
||||
!if "$(BUILD)" == "debug" && "$(DEBUG_RUNTIME_LIBS)" == "default"
|
||||
__DEBUGRUNTIME_5 =
|
||||
!endif
|
||||
!if "$(BUILD)" == "release" && "$(DEBUG_RUNTIME_LIBS)" == "default"
|
||||
__DEBUGRUNTIME_5 = /opt:ref /opt:icf
|
||||
!endif
|
||||
!if "$(DEBUG_RUNTIME_LIBS)" == "0"
|
||||
__DEBUGRUNTIME_5 = /opt:ref /opt:icf
|
||||
!endif
|
||||
!if "$(DEBUG_RUNTIME_LIBS)" == "1"
|
||||
__DEBUGRUNTIME_5 =
|
||||
!endif
|
||||
!if "$(BUILD)" == "debug"
|
||||
__OPTIMIZEFLAG_6 = /Od
|
||||
!endif
|
||||
!if "$(BUILD)" == "release"
|
||||
__OPTIMIZEFLAG_6 = /O2
|
||||
!endif
|
||||
!if "$(USE_THREADS)" == "0"
|
||||
__THREADSFLAG_9 = L
|
||||
!endif
|
||||
!if "$(USE_THREADS)" == "1"
|
||||
__THREADSFLAG_9 = T
|
||||
!endif
|
||||
!if "$(RUNTIME_LIBS)" == "dynamic"
|
||||
__RUNTIME_LIBS_10 = D
|
||||
!endif
|
||||
!if "$(RUNTIME_LIBS)" == "static"
|
||||
__RUNTIME_LIBS_10 = $(__THREADSFLAG_9)
|
||||
!endif
|
||||
!if "$(USE_RTTI)" == "0"
|
||||
__RTTIFLAG_11 = /GR-
|
||||
!endif
|
||||
!if "$(USE_RTTI)" == "1"
|
||||
__RTTIFLAG_11 = /GR
|
||||
!endif
|
||||
!if "$(USE_EXCEPTIONS)" == "0"
|
||||
__EXCEPTIONSFLAG_12 =
|
||||
!endif
|
||||
!if "$(USE_EXCEPTIONS)" == "1"
|
||||
__EXCEPTIONSFLAG_12 = /EHsc
|
||||
!endif
|
||||
!if "$(BUILD)" == "debug" && "$(DEBUG_RUNTIME_LIBS)" == "0"
|
||||
__NO_VC_CRTDBG_p = /D__NO_VC_CRTDBG__
|
||||
!endif
|
||||
!if "$(BUILD)" == "release" && "$(DEBUG_FLAG)" == "1"
|
||||
__NO_VC_CRTDBG_p = /D__NO_VC_CRTDBG__
|
||||
!endif
|
||||
!if "$(BUILD)" == "debug" && "$(DEBUG_RUNTIME_LIBS)" == "0"
|
||||
__NO_VC_CRTDBG_p_1 = /d __NO_VC_CRTDBG__
|
||||
!endif
|
||||
!if "$(BUILD)" == "release" && "$(DEBUG_FLAG)" == "1"
|
||||
__NO_VC_CRTDBG_p_1 = /d __NO_VC_CRTDBG__
|
||||
!endif
|
||||
!if "$(TARGET_CPU)" == ""
|
||||
__TARGET_CPU_COMPFLAG_p = /DTARGET_CPU_COMPFLAG=0
|
||||
!endif
|
||||
!if "$(TARGET_CPU)" == "" && "$(VISUALSTUDIOPLATFORM)" == "X64"
|
||||
__TARGET_CPU_COMPFLAG_p =
|
||||
!endif
|
||||
!if "$(TARGET_CPU)" == "" && "$(VISUALSTUDIOPLATFORM)" == "x64"
|
||||
__TARGET_CPU_COMPFLAG_p =
|
||||
!endif
|
||||
!if "$(TARGET_CPU)" == ""
|
||||
__TARGET_CPU_COMPFLAG_p_1 = /d TARGET_CPU_COMPFLAG=0
|
||||
!endif
|
||||
!if "$(TARGET_CPU)" == "" && "$(VISUALSTUDIOPLATFORM)" == "X64"
|
||||
__TARGET_CPU_COMPFLAG_p_1 =
|
||||
!endif
|
||||
!if "$(TARGET_CPU)" == "" && "$(VISUALSTUDIOPLATFORM)" == "x64"
|
||||
__TARGET_CPU_COMPFLAG_p_1 =
|
||||
!endif
|
||||
!if "$(WXUNIV)" == "1"
|
||||
__WXUNIV_DEFINE_p = /D__WXUNIVERSAL__
|
||||
!endif
|
||||
!if "$(WXUNIV)" == "1"
|
||||
__WXUNIV_DEFINE_p_1 = /d __WXUNIVERSAL__
|
||||
!endif
|
||||
!if "$(DEBUG_FLAG)" == "0"
|
||||
__DEBUG_DEFINE_p = /DwxDEBUG_LEVEL=0
|
||||
!endif
|
||||
!if "$(DEBUG_FLAG)" == "0"
|
||||
__DEBUG_DEFINE_p_1 = /d wxDEBUG_LEVEL=0
|
||||
!endif
|
||||
!if "$(BUILD)" == "release" && "$(DEBUG_RUNTIME_LIBS)" == "default"
|
||||
__NDEBUG_DEFINE_p = /DNDEBUG
|
||||
!endif
|
||||
!if "$(DEBUG_RUNTIME_LIBS)" == "0"
|
||||
__NDEBUG_DEFINE_p = /DNDEBUG
|
||||
!endif
|
||||
!if "$(BUILD)" == "release" && "$(DEBUG_RUNTIME_LIBS)" == "default"
|
||||
__NDEBUG_DEFINE_p_1 = /d NDEBUG
|
||||
!endif
|
||||
!if "$(DEBUG_RUNTIME_LIBS)" == "0"
|
||||
__NDEBUG_DEFINE_p_1 = /d NDEBUG
|
||||
!endif
|
||||
!if "$(USE_EXCEPTIONS)" == "0"
|
||||
__EXCEPTIONS_DEFINE_p = /DwxNO_EXCEPTIONS
|
||||
!endif
|
||||
!if "$(USE_EXCEPTIONS)" == "0"
|
||||
__EXCEPTIONS_DEFINE_p_1 = /d wxNO_EXCEPTIONS
|
||||
!endif
|
||||
!if "$(USE_RTTI)" == "0"
|
||||
__RTTI_DEFINE_p = /DwxNO_RTTI
|
||||
!endif
|
||||
!if "$(USE_RTTI)" == "0"
|
||||
__RTTI_DEFINE_p_1 = /d wxNO_RTTI
|
||||
!endif
|
||||
!if "$(USE_THREADS)" == "0"
|
||||
__THREAD_DEFINE_p = /DwxNO_THREADS
|
||||
!endif
|
||||
!if "$(USE_THREADS)" == "0"
|
||||
__THREAD_DEFINE_p_1 = /d wxNO_THREADS
|
||||
!endif
|
||||
!if "$(USE_CAIRO)" == "1"
|
||||
____CAIRO_INCLUDEDIR_FILENAMES_p = /I$(CAIRO_ROOT)\include\cairo
|
||||
!endif
|
||||
!if "$(USE_CAIRO)" == "1"
|
||||
____CAIRO_INCLUDEDIR_FILENAMES_1_p = /i $(CAIRO_ROOT)\include\cairo
|
||||
!endif
|
||||
!if "$(SHARED)" == "1"
|
||||
__DLLFLAG_p = /DWXUSINGDLL
|
||||
!endif
|
||||
!if "$(SHARED)" == "1"
|
||||
__DLLFLAG_p_1 = /d WXUSINGDLL
|
||||
!endif
|
||||
!if "$(MONOLITHIC)" == "0"
|
||||
__WXLIB_AUI_p = \
|
||||
wx$(PORTNAME)$(WXUNIVNAME)$(WX_RELEASE_NODOT)u$(WXDEBUGFLAG)$(WX_LIB_FLAVOUR)_aui.lib
|
||||
!endif
|
||||
!if "$(MONOLITHIC)" == "0"
|
||||
__WXLIB_CORE_p = \
|
||||
wx$(PORTNAME)$(WXUNIVNAME)$(WX_RELEASE_NODOT)u$(WXDEBUGFLAG)$(WX_LIB_FLAVOUR)_core.lib
|
||||
!endif
|
||||
!if "$(MONOLITHIC)" == "0"
|
||||
__WXLIB_BASE_p = \
|
||||
wxbase$(WX_RELEASE_NODOT)u$(WXDEBUGFLAG)$(WX_LIB_FLAVOUR).lib
|
||||
!endif
|
||||
!if "$(MONOLITHIC)" == "1"
|
||||
__WXLIB_MONO_p = \
|
||||
wx$(PORTNAME)$(WXUNIVNAME)$(WX_RELEASE_NODOT)u$(WXDEBUGFLAG)$(WX_LIB_FLAVOUR).lib
|
||||
!endif
|
||||
!if "$(MONOLITHIC)" == "1" && "$(USE_STC)" == "1"
|
||||
__LIB_SCINTILLA_IF_MONO_p = wxscintilla$(WXDEBUGFLAG).lib
|
||||
!endif
|
||||
!if "$(MONOLITHIC)" == "1" && "$(USE_STC)" == "1"
|
||||
__LIB_LEXILLA_IF_MONO_p = $(__LIB_LEXILLA_p)
|
||||
!endif
|
||||
!if "$(USE_STC)" == "1"
|
||||
__LIB_LEXILLA_p = wxlexilla$(WXDEBUGFLAG).lib
|
||||
!endif
|
||||
!if "$(USE_GUI)" == "1"
|
||||
__LIB_TIFF_p = wxtiff$(WXDEBUGFLAG).lib
|
||||
!endif
|
||||
!if "$(USE_GUI)" == "1"
|
||||
__LIB_JPEG_p = wxjpeg$(WXDEBUGFLAG).lib
|
||||
!endif
|
||||
!if "$(USE_GUI)" == "1"
|
||||
__LIB_PNG_p = wxpng$(WXDEBUGFLAG).lib
|
||||
!endif
|
||||
!if "$(USE_GUI)" == "1"
|
||||
__LIB_WEBP_p = wxwebp$(WXDEBUGFLAG).lib
|
||||
!endif
|
||||
!if "$(USE_CAIRO)" == "1"
|
||||
__CAIRO_LIB_p = cairo.lib
|
||||
!endif
|
||||
!if "$(USE_CAIRO)" == "1"
|
||||
____CAIRO_LIBDIR_FILENAMES_p = /LIBPATH:$(CAIRO_ROOT)\lib
|
||||
!endif
|
||||
|
||||
|
||||
all: $(OBJS)
|
||||
$(OBJS):
|
||||
-if not exist $(OBJS) mkdir $(OBJS)
|
||||
|
||||
### Targets: ###
|
||||
|
||||
all: $(OBJS)\docview.exe
|
||||
|
||||
clean:
|
||||
-if exist $(OBJS)\*.obj del $(OBJS)\*.obj
|
||||
-if exist $(OBJS)\*.res del $(OBJS)\*.res
|
||||
-if exist $(OBJS)\*.pch del $(OBJS)\*.pch
|
||||
-if exist $(OBJS)\docview.exe del $(OBJS)\docview.exe
|
||||
-if exist $(OBJS)\docview.ilk del $(OBJS)\docview.ilk
|
||||
-if exist $(OBJS)\docview.pdb del $(OBJS)\docview.pdb
|
||||
|
||||
$(OBJS)\docview.exe: $(DOCVIEW_OBJECTS) $(OBJS)\docview_docview.res
|
||||
link /NOLOGO /OUT:$@ $(__DEBUGINFO_1) /pdb:"$(OBJS)\docview.pdb" $(__DEBUGINFO_2) $(LINK_TARGET_CPU) /LIBPATH:$(LIBDIRNAME) $(WIN32_DPI_LINKFLAG) /SUBSYSTEM:WINDOWS $(____CAIRO_LIBDIR_FILENAMES_p) $(LDFLAGS) @<<
|
||||
$(DOCVIEW_OBJECTS) $(DOCVIEW_RESOURCES) $(__WXLIB_AUI_p) $(__WXLIB_CORE_p) $(__WXLIB_BASE_p) $(__WXLIB_MONO_p) $(__LIB_SCINTILLA_IF_MONO_p) $(__LIB_LEXILLA_IF_MONO_p) $(__LIB_TIFF_p) $(__LIB_JPEG_p) $(__LIB_PNG_p) $(__LIB_WEBP_p) wxzlib$(WXDEBUGFLAG).lib wxregexu$(WXDEBUGFLAG).lib wxexpat$(WXDEBUGFLAG).lib $(EXTRALIBS_FOR_BASE) $(__CAIRO_LIB_p) kernel32.lib user32.lib gdi32.lib gdiplus.lib msimg32.lib comdlg32.lib winspool.lib winmm.lib shell32.lib shlwapi.lib comctl32.lib ole32.lib oleaut32.lib uuid.lib rpcrt4.lib advapi32.lib version.lib ws2_32.lib wininet.lib
|
||||
<<
|
||||
|
||||
$(OBJS)\docview_docview.obj: .\docview.cpp
|
||||
$(CXX) /c /nologo /TP /Fo$@ $(DOCVIEW_CXXFLAGS) .\docview.cpp
|
||||
|
||||
$(OBJS)\docview_doc.obj: .\doc.cpp
|
||||
$(CXX) /c /nologo /TP /Fo$@ $(DOCVIEW_CXXFLAGS) .\doc.cpp
|
||||
|
||||
$(OBJS)\docview_view.obj: .\view.cpp
|
||||
$(CXX) /c /nologo /TP /Fo$@ $(DOCVIEW_CXXFLAGS) .\view.cpp
|
||||
|
||||
$(OBJS)\docview_docview.res: .\docview.rc
|
||||
rc /fo$@ /d WIN32 $(____DEBUGRUNTIME_3_p_1) /d _CRT_SECURE_NO_DEPRECATE=1 /d _CRT_NON_CONFORMING_SWPRINTFS=1 /d _SCL_SECURE_NO_WARNINGS=1 $(__NO_VC_CRTDBG_p_1) $(__TARGET_CPU_COMPFLAG_p_1) /d __WXMSW__ $(__WXUNIV_DEFINE_p_1) $(__DEBUG_DEFINE_p_1) $(__NDEBUG_DEFINE_p_1) $(__EXCEPTIONS_DEFINE_p_1) $(__RTTI_DEFINE_p_1) $(__THREAD_DEFINE_p_1) /i $(SETUPHDIR) /i .\..\..\include $(____CAIRO_INCLUDEDIR_FILENAMES_1_p) /i . $(__DLLFLAG_p_1) /d _WINDOWS /i .\..\..\samples /d NOPCH .\docview.rc
|
||||
|
||||
44
libs/wxWidgets-3.3.1/samples/docview/makefile.vms
Normal file
44
libs/wxWidgets-3.3.1/samples/docview/makefile.vms
Normal file
@@ -0,0 +1,44 @@
|
||||
#************************************************************************
|
||||
# Makefile for DOCVIEW under VMS
|
||||
# by Stefan Hammes
|
||||
# (incomplete) update history:
|
||||
# 09.06.95
|
||||
#************************************************************************
|
||||
|
||||
#************************************************************************
|
||||
# Definition section
|
||||
# (cave: definitions and includes must begin with ',')
|
||||
#************************************************************************
|
||||
|
||||
APPOPTS =
|
||||
APPDEFS =
|
||||
APPINCS =
|
||||
|
||||
#************************************************************************
|
||||
# Module section
|
||||
#************************************************************************
|
||||
|
||||
# Name of main module
|
||||
MAIN = docview
|
||||
|
||||
# Object modules of the application.
|
||||
OBJS = docview.obj view.obj doc.obj
|
||||
OBJLIST =docview.obj,view.obj,doc.obj
|
||||
|
||||
.include [--.src]makevms.env
|
||||
|
||||
# main dependency
|
||||
$(MAIN).exe : $(OBJS)
|
||||
$(LINK) $(LINKFLAGS) /exec=$(MAIN).exe $(OBJLIST),$(WXLIB)/lib,$(OPTSFILE)/option
|
||||
- purge *.exe
|
||||
|
||||
#************************************************************************
|
||||
# Header file depedencies following
|
||||
#************************************************************************
|
||||
|
||||
docview.$(OBJSUFF) : docview.$(SRCSUFF) docview.h doc.h view.h
|
||||
|
||||
doc.$(OBJSUFF) : doc.$(SRCSUFF) doc.h
|
||||
|
||||
view.$(OBJSUFF) : view.$(SRCSUFF) view.h
|
||||
|
||||
BIN
libs/wxWidgets-3.3.1/samples/docview/notepad.icns
Normal file
BIN
libs/wxWidgets-3.3.1/samples/docview/notepad.icns
Normal file
Binary file not shown.
BIN
libs/wxWidgets-3.3.1/samples/docview/notepad.ico
Normal file
BIN
libs/wxWidgets-3.3.1/samples/docview/notepad.ico
Normal file
Binary file not shown.
|
After Width: | Height: | Size: 766 B |
43
libs/wxWidgets-3.3.1/samples/docview/notepad.xpm
Normal file
43
libs/wxWidgets-3.3.1/samples/docview/notepad.xpm
Normal file
@@ -0,0 +1,43 @@
|
||||
/* XPM */
|
||||
static const char *notepad_xpm[] = {
|
||||
/* columns rows colors chars-per-pixel */
|
||||
"32 32 5 1",
|
||||
" c black",
|
||||
". c #808080",
|
||||
"X c #C0C0C0",
|
||||
"o c gray100",
|
||||
"O c None",
|
||||
/* pixels */
|
||||
"OOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOO",
|
||||
"OOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOO",
|
||||
"OOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOO",
|
||||
"OOOOOOOOO.OO.OO.OO.OO.OOOOOOOOOO",
|
||||
"OOOOOOXXX.XX.XX.XX.XX.XXXOOOOOOO",
|
||||
"OOOOOOXoo.oo.oo.oo.oo.ooXOOOOOOO",
|
||||
"OOOOOOXoooooooooooooooooX.OOOOOO",
|
||||
"OOOOOOXoo .. . ooX.OOOOOO",
|
||||
"OOOOOOXoooooooooooooooooX.OOOOOO",
|
||||
"OOOOOOXoooooooooooooooooX.OOOOOO",
|
||||
"OOOOOOXoo oooooooooX.OOOOOO",
|
||||
"OOOOOOXoooooooooooooooooX.OOOOOO",
|
||||
"OOOOOOXoooooooooooooooooX.OOOOOO",
|
||||
"OOOOOOXoo . ooooX.OOOOOO",
|
||||
"OOOOOOXoooooooooooooooooX.OOOOOO",
|
||||
"OOOOOOXoooooooooooooooooX.OOOOOO",
|
||||
"OOOOOOXoo . oooooX.OOOOOO",
|
||||
"OOOOOOXoooooooooooooooooX.OOOOOO",
|
||||
"OOOOOOXoooooooooooooooooX.OOOOOO",
|
||||
"OOOOOOXoo . . ooX.OOOOOO",
|
||||
"OOOOOOXoooooooooooooooooX.OOOOOO",
|
||||
"OOOOOOXoooooooooooooooooX.OOOOOO",
|
||||
"OOOOOOXoo . . oX.OOOOOO",
|
||||
"OOOOOOXoooooooooooooooooX.OOOOOO",
|
||||
"OOOOOOXoooooooooooooooooX.OOOOOO",
|
||||
"OOOOOOXoooooooooooooooooX.OOOOOO",
|
||||
"OOOOOOXXXXXXXXXXXXXXXXXXX.OOOOOO",
|
||||
"OOOOOOOO..................OOOOOO",
|
||||
"OOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOO",
|
||||
"OOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOO",
|
||||
"OOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOO",
|
||||
"OOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOO"
|
||||
};
|
||||
433
libs/wxWidgets-3.3.1/samples/docview/view.cpp
Normal file
433
libs/wxWidgets-3.3.1/samples/docview/view.cpp
Normal file
@@ -0,0 +1,433 @@
|
||||
/////////////////////////////////////////////////////////////////////////////
|
||||
// Name: samples/docview/view.cpp
|
||||
// Purpose: View classes implementation
|
||||
// Author: Julian Smart
|
||||
// Modified by: Vadim Zeitlin: merge with the MDI version and general cleanup
|
||||
// Created: 04/01/98
|
||||
// Copyright: (c) 1998 Julian Smart
|
||||
// (c) 2008 Vadim Zeitlin
|
||||
// Licence: wxWindows licence
|
||||
/////////////////////////////////////////////////////////////////////////////
|
||||
|
||||
// For compilers that support precompilation, includes "wx/wx.h".
|
||||
#include "wx/wxprec.h"
|
||||
|
||||
|
||||
#ifndef WX_PRECOMP
|
||||
#include "wx/wx.h"
|
||||
#endif
|
||||
|
||||
#if !wxUSE_DOC_VIEW_ARCHITECTURE
|
||||
#error You must set wxUSE_DOC_VIEW_ARCHITECTURE to 1 in setup.h!
|
||||
#endif
|
||||
|
||||
#include "docview.h"
|
||||
#include "doc.h"
|
||||
#include "view.h"
|
||||
|
||||
// ----------------------------------------------------------------------------
|
||||
// DrawingView implementation
|
||||
// ----------------------------------------------------------------------------
|
||||
|
||||
wxIMPLEMENT_DYNAMIC_CLASS(DrawingView, wxView);
|
||||
|
||||
wxBEGIN_EVENT_TABLE(DrawingView, wxView)
|
||||
EVT_MENU(wxID_CUT, DrawingView::OnCut)
|
||||
wxEND_EVENT_TABLE()
|
||||
|
||||
// What to do when a view is created. Creates actual
|
||||
// windows for displaying the view.
|
||||
bool DrawingView::OnCreate(wxDocument *doc, long flags)
|
||||
{
|
||||
if ( !wxView::OnCreate(doc, flags) )
|
||||
return false;
|
||||
|
||||
MyApp& app = wxGetApp();
|
||||
if ( app.GetMode() != MyApp::Mode_Single )
|
||||
{
|
||||
// create a new window and canvas inside it
|
||||
wxFrame* frame = app.CreateChildFrame(this, true);
|
||||
wxASSERT(frame == GetFrame());
|
||||
m_canvas = new MyCanvas(this);
|
||||
frame->Show();
|
||||
}
|
||||
else // single document mode
|
||||
{
|
||||
// reuse the existing window and canvas
|
||||
m_canvas = app.GetMainWindowCanvas();
|
||||
m_canvas->SetView(this);
|
||||
|
||||
// Initialize the edit menu Undo and Redo items
|
||||
doc->GetCommandProcessor()->SetEditMenu(app.GetMainWindowEditMenu());
|
||||
doc->GetCommandProcessor()->Initialize();
|
||||
}
|
||||
|
||||
return true;
|
||||
}
|
||||
|
||||
// Sneakily gets used for default print/preview as well as drawing on the
|
||||
// screen.
|
||||
void DrawingView::OnDraw(wxDC *dc)
|
||||
{
|
||||
dc->SetPen(*wxBLACK_PEN);
|
||||
|
||||
// simply draw all lines of all segments
|
||||
const DoodleSegments& segments = GetDocument()->GetSegments();
|
||||
for ( DoodleSegments::const_iterator i = segments.begin();
|
||||
i != segments.end();
|
||||
++i )
|
||||
{
|
||||
const DoodleLines& lines = i->GetLines();
|
||||
for ( DoodleLines::const_iterator j = lines.begin();
|
||||
j != lines.end();
|
||||
++j )
|
||||
{
|
||||
const DoodleLine& line = *j;
|
||||
|
||||
dc->DrawLine(line.x1, line.y1, line.x2, line.y2);
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
DrawingDocument* DrawingView::GetDocument()
|
||||
{
|
||||
return wxStaticCast(wxView::GetDocument(), DrawingDocument);
|
||||
}
|
||||
|
||||
void DrawingView::OnUpdate(wxView* sender, wxObject* hint)
|
||||
{
|
||||
wxView::OnUpdate(sender, hint);
|
||||
if ( m_canvas )
|
||||
m_canvas->Refresh();
|
||||
}
|
||||
|
||||
// Clean up windows used for displaying the view.
|
||||
bool DrawingView::OnClose(bool deleteWindow)
|
||||
{
|
||||
if ( !wxView::OnClose(deleteWindow) )
|
||||
return false;
|
||||
|
||||
Activate(false);
|
||||
|
||||
// Clear the canvas in single-window mode in which it stays alive
|
||||
if ( wxGetApp().GetMode() == MyApp::Mode_Single )
|
||||
{
|
||||
m_canvas->ClearBackground();
|
||||
m_canvas->ResetView();
|
||||
m_canvas = nullptr;
|
||||
|
||||
if (GetFrame())
|
||||
wxStaticCast(GetFrame(), wxFrame)->SetTitle(wxTheApp->GetAppDisplayName());
|
||||
}
|
||||
else // not single window mode
|
||||
{
|
||||
if ( deleteWindow )
|
||||
{
|
||||
GetFrame()->Destroy();
|
||||
SetFrame(nullptr);
|
||||
}
|
||||
}
|
||||
return true;
|
||||
}
|
||||
|
||||
void DrawingView::OnCut(wxCommandEvent& WXUNUSED(event) )
|
||||
{
|
||||
DrawingDocument * const doc = GetDocument();
|
||||
|
||||
doc->GetCommandProcessor()->Submit(new DrawingRemoveSegmentCommand(doc));
|
||||
}
|
||||
|
||||
// ----------------------------------------------------------------------------
|
||||
// TextEditView implementation
|
||||
// ----------------------------------------------------------------------------
|
||||
|
||||
wxIMPLEMENT_DYNAMIC_CLASS(TextEditView, wxView);
|
||||
|
||||
wxBEGIN_EVENT_TABLE(TextEditView, wxView)
|
||||
EVT_MENU(wxID_COPY, TextEditView::OnCopy)
|
||||
EVT_MENU(wxID_PASTE, TextEditView::OnPaste)
|
||||
EVT_MENU(wxID_SELECTALL, TextEditView::OnSelectAll)
|
||||
wxEND_EVENT_TABLE()
|
||||
|
||||
bool TextEditView::OnCreate(wxDocument *doc, long flags)
|
||||
{
|
||||
if ( !wxView::OnCreate(doc, flags) )
|
||||
return false;
|
||||
|
||||
wxFrame* frame = wxGetApp().CreateChildFrame(this, false);
|
||||
wxASSERT(frame == GetFrame());
|
||||
m_text = new wxTextCtrl(frame, wxID_ANY, "",
|
||||
wxDefaultPosition, wxDefaultSize,
|
||||
wxTE_MULTILINE);
|
||||
frame->Show();
|
||||
|
||||
return true;
|
||||
}
|
||||
|
||||
void TextEditView::OnDraw(wxDC *WXUNUSED(dc))
|
||||
{
|
||||
// nothing to do here, wxTextCtrl draws itself
|
||||
}
|
||||
|
||||
bool TextEditView::OnClose(bool deleteWindow)
|
||||
{
|
||||
if ( !wxView::OnClose(deleteWindow) )
|
||||
return false;
|
||||
|
||||
Activate(false);
|
||||
|
||||
if ( wxGetApp().GetMode() == MyApp::Mode_Single )
|
||||
{
|
||||
m_text->Clear();
|
||||
}
|
||||
else // not single window mode
|
||||
{
|
||||
if ( deleteWindow )
|
||||
{
|
||||
GetFrame()->Destroy();
|
||||
SetFrame(nullptr);
|
||||
}
|
||||
}
|
||||
return true;
|
||||
}
|
||||
|
||||
// ----------------------------------------------------------------------------
|
||||
// MyCanvas implementation
|
||||
// ----------------------------------------------------------------------------
|
||||
|
||||
wxBEGIN_EVENT_TABLE(MyCanvas, wxScrolledWindow)
|
||||
EVT_MOUSE_EVENTS(MyCanvas::OnMouseEvent)
|
||||
wxEND_EVENT_TABLE()
|
||||
|
||||
// Define a constructor for my canvas
|
||||
MyCanvas::MyCanvas(wxView *view, wxWindow *parent)
|
||||
: wxScrolledWindow(parent ? parent : view->GetFrame())
|
||||
{
|
||||
m_view = view;
|
||||
m_currentSegment = nullptr;
|
||||
m_lastMousePos = wxDefaultPosition;
|
||||
|
||||
SetCursor(wxCursor(wxCURSOR_PENCIL));
|
||||
|
||||
// this is completely arbitrary and is done just for illustration purposes
|
||||
SetVirtualSize(1000, 1000);
|
||||
SetScrollRate(20, 20);
|
||||
|
||||
SetBackgroundColour(*wxWHITE);
|
||||
}
|
||||
|
||||
MyCanvas::~MyCanvas()
|
||||
{
|
||||
delete m_currentSegment;
|
||||
}
|
||||
|
||||
// Define the repainting behaviour
|
||||
void MyCanvas::OnDraw(wxDC& dc)
|
||||
{
|
||||
if ( m_view )
|
||||
m_view->OnDraw(& dc);
|
||||
}
|
||||
|
||||
// This implements a tiny doodling program. Drag the mouse using the left
|
||||
// button.
|
||||
void MyCanvas::OnMouseEvent(wxMouseEvent& event)
|
||||
{
|
||||
if ( !m_view )
|
||||
return;
|
||||
|
||||
wxClientDC dc(this);
|
||||
PrepareDC(dc);
|
||||
|
||||
dc.SetPen(*wxBLACK_PEN);
|
||||
|
||||
const wxPoint pt(event.GetLogicalPosition(dc));
|
||||
|
||||
// is this the end of the current segment?
|
||||
if ( m_currentSegment && event.LeftUp() )
|
||||
{
|
||||
if ( !m_currentSegment->IsEmpty() )
|
||||
{
|
||||
// We've got a valid segment on mouse left up, so store it.
|
||||
DrawingDocument * const
|
||||
doc = wxStaticCast(m_view->GetDocument(), DrawingDocument);
|
||||
|
||||
doc->GetCommandProcessor()->Submit(
|
||||
new DrawingAddSegmentCommand(doc, *m_currentSegment));
|
||||
|
||||
doc->Modify(true);
|
||||
}
|
||||
|
||||
wxDELETE(m_currentSegment);
|
||||
}
|
||||
|
||||
// is this the start of a new segment?
|
||||
if ( m_lastMousePos != wxDefaultPosition && event.Dragging() )
|
||||
{
|
||||
if ( !m_currentSegment )
|
||||
m_currentSegment = new DoodleSegment;
|
||||
|
||||
m_currentSegment->AddLine(m_lastMousePos, pt);
|
||||
|
||||
dc.DrawLine(m_lastMousePos, pt);
|
||||
}
|
||||
|
||||
m_lastMousePos = pt;
|
||||
}
|
||||
|
||||
// ----------------------------------------------------------------------------
|
||||
// ImageCanvas implementation
|
||||
// ----------------------------------------------------------------------------
|
||||
|
||||
// Define a constructor for my canvas
|
||||
ImageCanvas::ImageCanvas(wxView* view)
|
||||
: wxScrolledWindow(view->GetFrame())
|
||||
{
|
||||
m_view = view;
|
||||
SetScrollRate( 10, 10 );
|
||||
}
|
||||
|
||||
// Define the repainting behaviour
|
||||
void ImageCanvas::OnDraw(wxDC& dc)
|
||||
{
|
||||
if ( m_view )
|
||||
m_view->OnDraw(& dc);
|
||||
}
|
||||
|
||||
// ----------------------------------------------------------------------------
|
||||
// ImageView implementation
|
||||
// ----------------------------------------------------------------------------
|
||||
|
||||
wxIMPLEMENT_DYNAMIC_CLASS(ImageView, wxView);
|
||||
|
||||
ImageDocument* ImageView::GetDocument()
|
||||
{
|
||||
return wxStaticCast(wxView::GetDocument(), ImageDocument);
|
||||
}
|
||||
|
||||
bool ImageView::OnCreate(wxDocument* doc, long flags)
|
||||
{
|
||||
if ( !wxView::OnCreate(doc, flags) )
|
||||
return false;
|
||||
|
||||
wxFrame* frame = wxGetApp().CreateChildFrame(this, false);
|
||||
wxASSERT(frame == GetFrame());
|
||||
m_canvas = new ImageCanvas(this);
|
||||
frame->Show();
|
||||
|
||||
return true;
|
||||
}
|
||||
|
||||
void ImageView::OnUpdate(wxView* sender, wxObject* hint)
|
||||
{
|
||||
wxView::OnUpdate(sender, hint);
|
||||
wxImage image = GetDocument()->GetImage();
|
||||
if ( image.IsOk() )
|
||||
{
|
||||
m_canvas->SetVirtualSize(image.GetWidth(), image.GetHeight());
|
||||
}
|
||||
}
|
||||
|
||||
void ImageView::OnDraw(wxDC* dc)
|
||||
{
|
||||
wxImage image = GetDocument()->GetImage();
|
||||
if ( image.IsOk() )
|
||||
{
|
||||
dc->DrawBitmap(wxBitmap(image), 0, 0, true /* use mask */);
|
||||
}
|
||||
}
|
||||
|
||||
bool ImageView::OnClose(bool deleteWindow)
|
||||
{
|
||||
if ( !wxView::OnClose(deleteWindow) )
|
||||
return false;
|
||||
|
||||
Activate(false);
|
||||
|
||||
if ( wxGetApp().GetMode() == MyApp::Mode_Single )
|
||||
{
|
||||
GetDocument()->DeleteContents();
|
||||
}
|
||||
else // not single window mode
|
||||
{
|
||||
if ( deleteWindow )
|
||||
{
|
||||
GetFrame()->Destroy();
|
||||
SetFrame(nullptr);
|
||||
}
|
||||
}
|
||||
return true;
|
||||
}
|
||||
|
||||
// ----------------------------------------------------------------------------
|
||||
// ImageDetailsView
|
||||
// ----------------------------------------------------------------------------
|
||||
|
||||
ImageDetailsView::ImageDetailsView(ImageDetailsDocument *doc)
|
||||
: wxView()
|
||||
{
|
||||
SetDocument(doc);
|
||||
|
||||
m_frame = wxGetApp().CreateChildFrame(this, false);
|
||||
m_frame->SetTitle("Image Details");
|
||||
|
||||
wxPanel * const panel = new wxPanel(m_frame);
|
||||
wxFlexGridSizer * const sizer = new wxFlexGridSizer(2, wxSize(5, 5));
|
||||
const wxSizerFlags
|
||||
flags = wxSizerFlags().Align(wxALIGN_CENTRE_VERTICAL).Border();
|
||||
|
||||
sizer->Add(new wxStaticText(panel, wxID_ANY, "Image &file:"), flags);
|
||||
sizer->Add(new wxStaticText(panel, wxID_ANY, doc->GetFilename()), flags);
|
||||
|
||||
sizer->Add(new wxStaticText(panel, wxID_ANY, "Image &type:"), flags);
|
||||
wxString typeStr;
|
||||
switch ( doc->GetType() )
|
||||
{
|
||||
case wxBITMAP_TYPE_PNG:
|
||||
typeStr = "PNG";
|
||||
break;
|
||||
|
||||
case wxBITMAP_TYPE_JPEG:
|
||||
typeStr = "JPEG";
|
||||
break;
|
||||
|
||||
default:
|
||||
typeStr = "Unknown";
|
||||
}
|
||||
sizer->Add(new wxStaticText(panel, wxID_ANY, typeStr), flags);
|
||||
|
||||
sizer->Add(new wxStaticText(panel, wxID_ANY, "Image &size:"), flags);
|
||||
wxSize size = doc->GetSize();
|
||||
sizer->Add(new wxStaticText(panel, wxID_ANY,
|
||||
wxString::Format("%d*%d", size.x, size.y)),
|
||||
flags);
|
||||
|
||||
sizer->Add(new wxStaticText(panel, wxID_ANY, "Number of unique &colours:"),
|
||||
flags);
|
||||
sizer->Add(new wxStaticText(panel, wxID_ANY,
|
||||
wxString::Format("%lu", doc->GetNumColours())),
|
||||
flags);
|
||||
|
||||
sizer->Add(new wxStaticText(panel, wxID_ANY, "Uses &alpha:"), flags);
|
||||
sizer->Add(new wxStaticText(panel, wxID_ANY,
|
||||
doc->HasAlpha() ? "Yes" : "No"), flags);
|
||||
|
||||
panel->SetSizer(sizer);
|
||||
m_frame->SetClientSize(panel->GetBestSize());
|
||||
m_frame->Show(true);
|
||||
}
|
||||
|
||||
void ImageDetailsView::OnDraw(wxDC * WXUNUSED(dc))
|
||||
{
|
||||
// nothing to do here, we use controls to show our information
|
||||
}
|
||||
|
||||
bool ImageDetailsView::OnClose(bool deleteWindow)
|
||||
{
|
||||
if ( wxGetApp().GetMode() != MyApp::Mode_Single && deleteWindow )
|
||||
{
|
||||
delete m_frame;
|
||||
m_frame = nullptr;
|
||||
}
|
||||
|
||||
return true;
|
||||
}
|
||||
168
libs/wxWidgets-3.3.1/samples/docview/view.h
Normal file
168
libs/wxWidgets-3.3.1/samples/docview/view.h
Normal file
@@ -0,0 +1,168 @@
|
||||
/////////////////////////////////////////////////////////////////////////////
|
||||
// Name: samples/docview/view.h
|
||||
// Purpose: View classes
|
||||
// Author: Julian Smart
|
||||
// Modified by: Vadim Zeitlin: merge with the MDI version and general cleanup
|
||||
// Created: 04/01/98
|
||||
// Copyright: (c) 1998 Julian Smart
|
||||
// (c) 2008 Vadim Zeitlin
|
||||
// Licence: wxWindows licence
|
||||
/////////////////////////////////////////////////////////////////////////////
|
||||
|
||||
#ifndef _WX_SAMPLES_DOCVIEW_VIEW_H_
|
||||
#define _WX_SAMPLES_DOCVIEW_VIEW_H_
|
||||
|
||||
#include "wx/docview.h"
|
||||
|
||||
// ----------------------------------------------------------------------------
|
||||
// Drawing view classes
|
||||
// ----------------------------------------------------------------------------
|
||||
|
||||
// The window showing the drawing itself
|
||||
class MyCanvas : public wxScrolledWindow
|
||||
{
|
||||
public:
|
||||
// view may be null if we're not associated with one yet, but parent must
|
||||
// be a valid pointer
|
||||
MyCanvas(wxView *view, wxWindow *parent = nullptr);
|
||||
virtual ~MyCanvas();
|
||||
|
||||
virtual void OnDraw(wxDC& dc) override;
|
||||
|
||||
// in a normal multiple document application a canvas is associated with
|
||||
// one view from the beginning until the end, but to support the single
|
||||
// document mode in which all documents reuse the same MyApp::GetCanvas()
|
||||
// we need to allow switching the canvas from one view to another one
|
||||
|
||||
void SetView(wxView *view)
|
||||
{
|
||||
wxASSERT_MSG( !m_view, "shouldn't be already associated with a view" );
|
||||
|
||||
m_view = view;
|
||||
}
|
||||
|
||||
void ResetView()
|
||||
{
|
||||
wxASSERT_MSG( m_view, "should be associated with a view" );
|
||||
|
||||
m_view = nullptr;
|
||||
}
|
||||
|
||||
private:
|
||||
void OnMouseEvent(wxMouseEvent& event);
|
||||
|
||||
wxView *m_view;
|
||||
|
||||
// the segment being currently drawn or nullptr if none
|
||||
DoodleSegment *m_currentSegment;
|
||||
|
||||
// the last mouse press position
|
||||
wxPoint m_lastMousePos;
|
||||
|
||||
wxDECLARE_EVENT_TABLE();
|
||||
};
|
||||
|
||||
// The view using MyCanvas to show its contents
|
||||
class DrawingView : public wxView
|
||||
{
|
||||
public:
|
||||
DrawingView() : wxView(), m_canvas(nullptr) {}
|
||||
|
||||
virtual bool OnCreate(wxDocument *doc, long flags) override;
|
||||
virtual void OnDraw(wxDC *dc) override;
|
||||
virtual void OnUpdate(wxView *sender, wxObject *hint = nullptr) override;
|
||||
virtual bool OnClose(bool deleteWindow = true) override;
|
||||
|
||||
DrawingDocument* GetDocument();
|
||||
|
||||
private:
|
||||
void OnCut(wxCommandEvent& event);
|
||||
|
||||
MyCanvas *m_canvas;
|
||||
|
||||
wxDECLARE_EVENT_TABLE();
|
||||
wxDECLARE_DYNAMIC_CLASS(DrawingView);
|
||||
};
|
||||
|
||||
// ----------------------------------------------------------------------------
|
||||
// Text view classes
|
||||
// ----------------------------------------------------------------------------
|
||||
|
||||
// The view using a standard wxTextCtrl to show its contents
|
||||
class TextEditView : public wxView
|
||||
{
|
||||
public:
|
||||
TextEditView() : wxView(), m_text(nullptr) {}
|
||||
|
||||
virtual bool OnCreate(wxDocument *doc, long flags) override;
|
||||
virtual void OnDraw(wxDC *dc) override;
|
||||
virtual bool OnClose(bool deleteWindow = true) override;
|
||||
|
||||
wxTextCtrl *GetText() const { return m_text; }
|
||||
|
||||
private:
|
||||
void OnCopy(wxCommandEvent& WXUNUSED(event)) { m_text->Copy(); }
|
||||
void OnPaste(wxCommandEvent& WXUNUSED(event)) { m_text->Paste(); }
|
||||
void OnSelectAll(wxCommandEvent& WXUNUSED(event)) { m_text->SelectAll(); }
|
||||
|
||||
wxTextCtrl *m_text;
|
||||
|
||||
wxDECLARE_EVENT_TABLE();
|
||||
wxDECLARE_DYNAMIC_CLASS(TextEditView);
|
||||
};
|
||||
|
||||
// ----------------------------------------------------------------------------
|
||||
// ImageCanvas
|
||||
// ----------------------------------------------------------------------------
|
||||
|
||||
class ImageCanvas : public wxScrolledWindow
|
||||
{
|
||||
public:
|
||||
ImageCanvas(wxView*);
|
||||
|
||||
virtual void OnDraw(wxDC& dc) override;
|
||||
private:
|
||||
wxView *m_view;
|
||||
};
|
||||
|
||||
// ----------------------------------------------------------------------------
|
||||
// ImageView
|
||||
// ----------------------------------------------------------------------------
|
||||
|
||||
class ImageView : public wxView
|
||||
{
|
||||
public:
|
||||
ImageView() : wxView() {}
|
||||
|
||||
virtual bool OnCreate(wxDocument*, long flags) override;
|
||||
virtual void OnDraw(wxDC*) override;
|
||||
virtual bool OnClose(bool deleteWindow = true) override;
|
||||
virtual void OnUpdate(wxView *sender, wxObject *hint = nullptr) override;
|
||||
|
||||
ImageDocument* GetDocument();
|
||||
|
||||
private:
|
||||
ImageCanvas* m_canvas;
|
||||
|
||||
wxDECLARE_DYNAMIC_CLASS(ImageView);
|
||||
};
|
||||
|
||||
// ----------------------------------------------------------------------------
|
||||
// ImageDetailsView
|
||||
// ----------------------------------------------------------------------------
|
||||
|
||||
class ImageDetailsView : public wxView
|
||||
{
|
||||
public:
|
||||
ImageDetailsView(ImageDetailsDocument *doc);
|
||||
ImageDetailsView(const ImageDetailsView&) = delete;
|
||||
ImageDetailsView& operator=(const ImageDetailsView&) = delete;
|
||||
|
||||
virtual void OnDraw(wxDC *dc) override;
|
||||
virtual bool OnClose(bool deleteWindow) override;
|
||||
|
||||
private:
|
||||
wxFrame *m_frame;
|
||||
};
|
||||
|
||||
#endif // _WX_SAMPLES_DOCVIEW_VIEW_H_
|
||||
Reference in New Issue
Block a user